/**
 * Bespoke Nordic Architectural & Editorial Stylesheet
 * Palette: Nordic Sage & Muted Emerald
 * haranadh.com
 */

/* ==========================================================================
   1. Design System Tokens & Base Setup
   ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  /* Color Palette - Premium Nordic Sage & Muted Emerald */
  --bg-primary: #F3F5F3; /* Pristine Sage Chalk / Pale Ash */
  --bg-secondary: #FFFFFF;
  --bg-glass: rgba(255, 255, 255, 0.65);
  --bg-glass-heavy: rgba(255, 255, 255, 0.92);
  
  --border-color: rgba(20, 28, 26, 0.05); /* Architectural thin border */
  --border-color-hover: rgba(13, 122, 95, 0.18);
  --border-color-glow: rgba(13, 122, 95, 0.12);
  
  --text-primary: #141C1A; /* Dark Forest Obsidian / Rich Black-Green */
  --text-secondary: #45524F; /* Forest Slate Charcoal */
  --text-muted: #8B9B97;
  
  --accent-indigo: #0D7A5F; /* Muted Emerald Accent */
  --accent-indigo-hover: #0A5E49;
  --accent-blue: #25545E; /* Cold Steel / Teal-Blue Accent */
  
  --gradient-accent: linear-gradient(135deg, #0D7A5F 0%, #25545E 100%);
  --gradient-card-hover: linear-gradient(135deg, rgba(13, 122, 95, 0.015) 0%, rgba(37, 84, 94, 0.015) 100%);
  
  /* Mesh Gradients */
  --mesh-gradient: radial-gradient(at 0% 0%, rgba(13, 122, 95, 0.035) 0px, transparent 50%), 
                   radial-gradient(at 100% 100%, rgba(37, 84, 94, 0.02) 0px, transparent 50%),
                   radial-gradient(at 50% 50%, rgba(13, 122, 95, 0.01) 0px, transparent 40%);

  /* Shadow Systems */
  --shadow-sm: 0 4px 20px rgba(20, 28, 26, 0.01);
  --shadow-md: 0 12px 30px rgba(20, 28, 26, 0.03);
  --shadow-lg: 0 24px 50px rgba(20, 28, 26, 0.05);
  --shadow-glow: 0 0 30px rgba(13, 122, 95, 0.06);
  
  /* Layout Dimensions */
  --max-width: 1140px;
  --header-height: 80px;
  --border-radius-sm: 6px; /* Sharper geometric aesthetic */
  --border-radius-md: 12px;
  --border-radius-lg: 20px;
  
  /* Transitions - Architectural EaseOutExpo */
  --transition-smooth: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-size: 16px;
}

body {
  background-color: var(--bg-primary);
  background-image: var(--mesh-gradient);
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  line-height: 1.65;
  overflow-x: hidden;
  position: relative;
}

/* Subtle Technical Grid Overlay */
body::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    linear-gradient(rgba(20, 28, 26, 0.012) 1px, transparent 1px),
    linear-gradient(90deg, rgba(20, 28, 26, 0.012) 1px, transparent 1px);
  background-size: 80px 80px;
  background-position: center top;
  pointer-events: none;
  z-index: -2;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Plus Jakarta Sans', sans-serif;
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.5px;
}

a {
  color: var(--accent-indigo);
  text-decoration: none;
  transition: var(--transition-fast);
}

a:hover {
  color: var(--accent-indigo-hover);
}

button {
  cursor: pointer;
  border: none;
  outline: none;
  background: none;
  font-family: inherit;
  transition: var(--transition-smooth);
}

/* Minimalist Architectural Scrollbar */
::-webkit-scrollbar {
  width: 6px;
}
::-webkit-scrollbar-track {
  background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
  background: rgba(20, 28, 26, 0.15);
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(20, 28, 26, 0.3);
}

/* Layout Containers */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 28px;
  position: relative;
}

.section-padding {
  padding: 120px 0;
  border-bottom: 1px solid rgba(20, 28, 26, 0.04);
}

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

/* Custom Glassmorphic Architectural Cards */
.glass-card {
  background: var(--bg-glass);
  border: 1px solid var(--border-color);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.glass-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--gradient-accent);
  opacity: 0;
  transition: var(--transition-smooth);
}

.glass-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--border-color-hover);
  background: var(--bg-secondary);
}

.glass-card:hover::before {
  opacity: 1;
}

/* ==========================================================================
   2. Dashboard Layout & Sidebar Console
   ========================================================================== */
.dashboard-wrapper {
  display: flex;
  min-height: 100vh;
  position: relative;
  width: 100%;
}

/* LEFT SIDEBAR PANEL */
.console-sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: 300px;
  background: var(--bg-glass-heavy);
  border-right: 1px solid var(--border-color);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  padding: 40px 24px;
  display: flex;
  flex-direction: column;
  z-index: 100;
  box-shadow: 6px 0 30px rgba(20, 28, 26, 0.02);
  transition: var(--transition-smooth);
}

.sidebar-brand-wrapper {
  margin-bottom: 40px;
  display: flex;
  align-items: center;
  width: 100%;
}

.logo-lockup {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  width: 100%;
}

.logo-icon {
  width: 44px;
  height: 44px;
  background: rgba(13, 122, 95, 0.08);
  border: 1px solid rgba(13, 122, 95, 0.25);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-indigo);
  font-weight: 800;
  font-size: 1.4rem;
  font-family: 'Plus Jakarta Sans', sans-serif;
  box-shadow: 0 4px 12px rgba(13, 122, 95, 0.06);
  transition: var(--transition-smooth);
  flex-shrink: 0;
}

.logo-lockup:hover .logo-icon {
  background: var(--gradient-accent);
  color: white;
  border-color: var(--accent-indigo);
  transform: translateY(-2px) rotate(-3deg);
  box-shadow: 0 6px 15px rgba(13, 122, 95, 0.2);
}

.logo-identity {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.logo-name {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.3px;
  transition: var(--transition-fast);
}

.logo-lockup:hover .logo-name {
  color: var(--accent-indigo);
}

.logo-subtitle {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-top: 2px;
  opacity: 0.85;
}

/* Nav Links - Console Dashboard style */
.console-nav {
  margin-bottom: auto;
}

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

.console-nav .nav-links li {
  width: 100%;
}

.console-nav .nav-links a {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-secondary);
  padding: 12px 16px;
  border-radius: var(--border-radius-sm);
  transition: var(--transition-fast);
  border: 1px solid transparent;
}

.console-nav .nav-links a i {
  font-size: 0.95rem;
  width: 16px;
  text-align: center;
  opacity: 0.7;
}

.console-nav .nav-links a:hover {
  color: var(--text-primary);
  background: rgba(20, 28, 26, 0.02);
  border-color: var(--border-color);
}

.console-nav .nav-links a.active {
  color: white;
  background: var(--gradient-accent);
  border-color: var(--accent-indigo);
  box-shadow: 0 4px 12px rgba(13, 122, 95, 0.15);
}

.console-nav .nav-links a.active i {
  opacity: 1;
}

/* Telemetry Monospace Widget */
.telemetry-widget {
  margin-top: 24px;
  padding: 16px;
  background: #141C1A; /* Dark code console terminal */
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--border-radius-sm);
  font-family: 'Courier New', Courier, monospace;
}

.telemetry-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.7rem;
  color: #8B9B97;
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 12px;
}

.telemetry-dot {
  width: 6px;
  height: 6px;
  background: #10B981; /* Green operational dot */
  border-radius: 50%;
  display: inline-block;
  animation: pulseGreen 2s infinite;
  box-shadow: 0 0 8px #10B981;
}

@keyframes pulseGreen {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

.telemetry-grid {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.telemetry-item {
  display: flex;
  justify-content: space-between;
  font-size: 0.68rem;
  line-height: 1.3;
}

.tel-label {
  color: #8B9B97;
}

.tel-val {
  color: #10B981; /* Terminal green */
  font-weight: 600;
}

/* Sidebar social & footer */
.sidebar-social {
  display: flex;
  gap: 16px;
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
}

.sidebar-social a {
  color: var(--text-secondary);
  font-size: 1.15rem;
  transition: var(--transition-fast);
}

.sidebar-social a:hover {
  color: var(--accent-indigo);
  transform: translateY(-2px);
}

/* RIGHT MAIN CONSOLE */
.console-main {
  flex-grow: 1;
  margin-left: 300px;
  width: calc(100% - 300px);
  position: relative;
  transition: var(--transition-smooth);
}

/* Adjust Section Padding Inside Dashboard */
.console-main .section-padding {
  padding: 100px 48px;
}

/* Re-adjust hero top spacing */
.console-main .hero {
  min-height: 100vh;
  padding-top: 60px;
}

/* Responsive Dashboard Mappings */
@media (max-width: 992px) {
  .console-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 60px;
    bottom: auto;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    border-right: none;
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 4px 20px rgba(20, 28, 26, 0.02);
  }

  .sidebar-brand-wrapper {
    margin-bottom: 0;
  }

  .sidebar-profile, 
  .telemetry-widget, 
  .sidebar-social {
    display: none;
  }

  .console-nav {
    margin-bottom: 0;
  }

  .console-nav .nav-links {
    flex-direction: row;
    gap: 8px;
  }

  .console-nav .nav-links a {
    padding: 8px 12px;
    font-size: 0.8rem;
    border: none;
  }

  .console-nav .nav-links a i {
    display: none; /* Hide icons in top narrow view */
  }

  .console-nav .nav-links a.active {
    box-shadow: none;
  }

  .console-main {
    margin-left: 0;
    width: 100%;
    padding-top: 60px;
  }

  .console-main .section-padding {
    padding: 80px 20px;
  }
}

@media (max-width: 640px) {
  .console-sidebar {
    padding: 0 16px;
  }
  .console-nav .nav-links {
    gap: 2px;
  }
  .console-nav .nav-links a {
    padding: 6px 8px;
    font-size: 0.72rem;
  }
}

/* ==========================================================================
   3. Editorial Asymmetric Hero Section
   ========================================================================== */
.hero {
  min-height: 95vh;
  display: flex;
  align-items: center;
  position: relative;
  padding-top: calc(var(--header-height) + 40px);
  margin-bottom: 0;
}

.hero-content {
  max-width: 820px;
  animation: fadeInUp 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.hero-tagline {
  display: inline-block;
  padding: 5px 14px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  border-radius: 4px; /* Sharper */
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent-indigo);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 28px;
}

.hero h1 {
  font-size: clamp(2.8rem, 6vw, 4.4rem);
  letter-spacing: -2px;
  margin-bottom: 28px;
  line-height: 1.1;
  font-weight: 800;
}

.hero h1 span {
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: 44px;
  line-height: 1.75;
  font-weight: 400;
}

.hero-subtitle strong {
  font-weight: 600;
  color: var(--text-primary);
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* Executive Telemetry Grid inside Hero */
.hero-stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 40px;
  margin-bottom: 48px;
  width: 100%;
}

@media (max-width: 820px) {
  .hero-stats-row {
    grid-template-columns: 1fr;
    gap: 16px;
    margin-bottom: 36px;
  }
}

.hero-stat-card {
  padding: 24px;
  display: flex;
  gap: 16px;
  align-items: flex-start;
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-color);
  background: rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: var(--transition-smooth);
}

.hero-stat-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-color-hover);
  background: var(--bg-secondary);
}

.hero-stat-card .stat-icon {
  width: 40px;
  height: 40px;
  background: rgba(13, 122, 95, 0.06);
  border: 1px solid rgba(13, 122, 95, 0.2);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-indigo);
  font-size: 1.15rem;
  flex-shrink: 0;
  transition: var(--transition-smooth);
}

.hero-stat-card:hover .stat-icon {
  background: var(--accent-indigo);
  color: white;
  border-color: var(--accent-indigo);
}

.hero-stat-card .stat-content {
  display: flex;
  flex-direction: column;
}

.hero-stat-card .stat-value {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 4px;
  letter-spacing: -0.2px;
}

.hero-stat-card .stat-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.4;
  font-weight: 500;
}

/* Sleek Rectangular Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 32px;
  font-size: 0.92rem;
  font-weight: 700;
  border-radius: var(--border-radius-sm);
  transition: var(--transition-smooth);
  letter-spacing: -0.2px;
}

.btn-primary {
  background: var(--gradient-accent);
  color: white;
  box-shadow: 0 4px 15px rgba(13, 122, 95, 0.15);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(13, 122, 95, 0.25);
  color: white;
}

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

.btn-secondary:hover {
  background: var(--bg-primary);
  border-color: rgba(20, 28, 26, 0.15);
  transform: translateY(-3px);
  color: var(--text-primary);
}

/* Scroll indicator */
.scroll-indicator {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  gap: 10px;
  animation: bounce 2.2s infinite;
}

.scroll-indicator i {
  font-size: 0.8rem;
}

/* ==========================================================================
   4. Section Header (Editorial)
   ========================================================================== */
.section-header {
  margin-bottom: 80px;
}

.section-label {
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2.5px;
  color: var(--accent-indigo);
  margin-bottom: 14px;
  display: block;
}

.section-title {
  font-size: clamp(2.2rem, 4vw, 2.8rem);
  letter-spacing: -0.8px;
  margin-bottom: 20px;
  font-weight: 700;
}

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

.left-aligned {
  text-align: left;
}

.left-aligned .section-subtitle {
  margin-left: 0;
}

/* ==========================================================================
   5. Production System Architectures
   ========================================================================== */
.systems-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 36px;
}

@media (max-width: 992px) {
  .systems-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}

.system-card {
  cursor: pointer;
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-color);
}

.system-card-top {
  padding: 36px;
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

.system-icon {
  width: 52px;
  height: 52px;
  background: var(--bg-primary);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  color: var(--accent-indigo);
  border: 1px solid var(--border-color);
  flex-shrink: 0;
  transition: var(--transition-smooth);
}

.system-card:hover .system-icon {
  background: var(--accent-indigo);
  color: white;
  border-color: var(--accent-indigo);
  transform: rotate(-5deg) scale(1.05);
}

.system-summary h3 {
  font-size: 1.35rem;
  margin-bottom: 10px;
  letter-spacing: -0.3px;
  font-weight: 700;
}

.system-summary p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

.system-card-body {
  padding: 0 36px 36px 36px;
}

.system-detailed-info {
  border-top: 1px dashed rgba(20, 28, 26, 0.08);
  padding-top: 24px;
  margin-top: 16px;
  overflow: hidden;
  transition: var(--transition-smooth);
  max-height: 500px;
  opacity: 1;
}

.system-detailed-info.collapsed {
  max-height: 0;
  opacity: 0;
  padding-top: 0;
  margin-top: 0;
  border-top-color: transparent;
}

.system-detailed-info h4 {
  font-size: 0.82rem;
  text-transform: uppercase;
  color: var(--text-muted);
  letter-spacing: 0.8px;
  margin-bottom: 14px;
  font-weight: 700;
}

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

.system-features li {
  font-size: 0.9rem;
  color: var(--text-secondary);
  display: flex;
  align-items: flex-start;
  gap: 10px;
  line-height: 1.5;
}

.system-features li i {
  color: #10B981;
  font-size: 0.85rem;
  margin-top: 4px;
}

.system-expand-bar {
  padding: 14px 36px;
  background: rgba(20, 28, 26, 0.01);
  border-top: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.system-card:hover .system-expand-bar {
  color: var(--accent-indigo);
  background: rgba(13, 122, 95, 0.015);
}

/* ==========================================================================
   6. Publications & Research (Dynamic Cards)
   ========================================================================== */
.filter-tabs {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 56px;
  flex-wrap: wrap;
}

.pub-filter-btn {
  padding: 10px 22px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  border-radius: 4px; /* Sleeker sharpness */
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-smooth);
}

.pub-filter-btn:hover {
  background: var(--bg-primary);
  border-color: rgba(20, 28, 26, 0.15);
}

.pub-filter-btn.active {
  background: var(--text-primary);
  color: white;
  border-color: var(--text-primary);
  box-shadow: var(--shadow-md);
}

.publications-grid {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.publication-card {
  padding: 40px;
  display: flex;
  flex-direction: column;
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-glass);
}

.pub-header {
  margin-bottom: 16px;
}

.pub-venue {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent-indigo);
  text-transform: uppercase;
  letter-spacing: 1px;
  display: block;
  margin-bottom: 10px;
}

.pub-title {
  font-size: 1.45rem;
  margin-bottom: 10px;
  letter-spacing: -0.3px;
  line-height: 1.3;
  font-weight: 700;
}

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

.pub-body {
  margin-bottom: 24px;
}

.pub-abstract {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

.pub-abstract.collapsed {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.toggle-abstract-btn {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent-indigo);
  margin-top: 10px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.toggle-abstract-btn i {
  transition: var(--transition-fast);
}

.toggle-abstract-btn.expanded i {
  transform: rotate(180deg);
}

.pub-tags-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.card-tag {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 10px;
  background: rgba(20, 28, 26, 0.03);
  color: var(--text-secondary);
  border-radius: 3px;
  border: 1px solid rgba(20, 28, 26, 0.015);
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.pub-footer-links {
  border-top: 1px solid var(--border-color);
  padding-top: 20px;
  display: flex;
  gap: 24px;
}

.pub-link {
  font-size: 0.88rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.pub-link i {
  font-size: 0.95rem;
}

/* ==========================================================================
   7. Technical AI Systems Blog
   ========================================================================== */
.blog-search-bar {
  max-width: 520px;
  margin: 0 auto 56px auto;
  position: relative;
}

.blog-search-bar input {
  width: 100%;
  padding: 16px 24px 16px 52px;
  border-radius: 4px; /* Sharper */
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
  box-shadow: var(--shadow-sm);
  outline: none;
  font-size: 0.95rem;
  color: var(--text-primary);
  font-family: inherit;
  transition: var(--transition-smooth);
}

.blog-search-bar input:focus {
  border-color: var(--accent-indigo);
  box-shadow: var(--shadow-glow);
}

.blog-search-bar i {
  position: absolute;
  left: 22px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 1rem;
}

.blogs-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 36px;
}

@media (max-width: 820px) {
  .blogs-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}

.blog-card {
  padding: 40px;
  display: flex;
  flex-direction: column;
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-glass);
}

.blog-card.featured {
  grid-column: span 2;
  background: linear-gradient(135deg, var(--bg-secondary) 0%, rgba(13, 122, 95, 0.015) 100%);
  border-left: 3px solid var(--accent-indigo);
}

@media (max-width: 820px) {
  .blog-card.featured {
    grid-column: span 1;
  }
}

.blog-meta-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.blog-title {
  font-size: 1.55rem;
  margin-bottom: 14px;
  line-height: 1.3;
  letter-spacing: -0.3px;
  font-weight: 700;
}

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

.blog-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-top: auto;
  border-top: 1px solid rgba(20, 28, 26, 0.04);
  padding-top: 20px;
}

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

.btn-text {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--accent-indigo);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.btn-text:hover {
  color: var(--accent-indigo-hover);
}

.btn-text i {
  transition: var(--transition-fast);
}

.btn-text:hover i {
  transform: translateX(4px);
}

/* ==========================================================================
   9. Architectural Left-Aligned Career Timeline
   ========================================================================== */
.timeline {
  position: relative;
  max-width: 860px;
  margin: 0 auto;
  padding: 20px 0;
}

/* Left vertical architectural line */
.timeline::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 20px;
  width: 1px;
  background: rgba(20, 28, 26, 0.08);
}

.timeline-item {
  position: relative;
  margin-bottom: 56px;
  width: 100% !important;
  left: 0 !important;
  padding-left: 60px !important;
  padding-right: 0 !important;
  text-align: left !important;
}

.timeline-badge {
  position: absolute;
  top: 8px;
  left: 14px;
  width: 13px;
  height: 13px;
  background: var(--bg-primary);
  border: 2px solid var(--accent-indigo);
  border-radius: 50%;
  z-index: 10;
  transition: var(--transition-smooth);
}

.timeline-item:hover .timeline-badge {
  background: var(--accent-indigo);
  transform: scale(1.3);
  box-shadow: 0 0 12px rgba(13, 122, 95, 0.4);
}

.timeline-date {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--accent-indigo);
  margin-bottom: 8px;
  display: block;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.timeline-content {
  display: block;
}

.timeline-content h3 {
  font-size: 1.3rem;
  margin-bottom: 6px;
  letter-spacing: -0.2px;
  font-weight: 700;
}

.timeline-content h4 {
  font-size: 0.95rem;
  color: var(--text-secondary);
  font-weight: 600;
  margin-bottom: 12px;
}

.timeline-content p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* Executive Leadership Highlights */
.executive-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  background: rgba(13, 122, 95, 0.06);
  border: 1px solid rgba(13, 122, 95, 0.22);
  color: var(--accent-indigo);
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: 4px;
  margin-left: 8px;
  vertical-align: middle;
}

.timeline-item.executive .timeline-badge {
  background: var(--accent-indigo);
  border-color: var(--accent-indigo);
  transform: scale(1.3);
  box-shadow: 0 0 12px rgba(13, 122, 95, 0.4);
}

.timeline-item.executive .timeline-content h3 {
  color: var(--accent-indigo);
}

/* ==========================================================================
   10. Connect & Contact Card
   ========================================================================== */
.contact-section {
  padding-bottom: 80px;
  border-bottom: none;
}

.contact-card {
  max-width: 680px;
  margin: 0 auto;
  padding: 56px;
  text-align: center;
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-md);
}

.contact-card h3 {
  font-size: 2rem;
  margin-bottom: 16px;
  font-weight: 700;
}

.contact-card p {
  color: var(--text-secondary);
  margin-bottom: 40px;
  font-size: 1.05rem;
  line-height: 1.65;
}

.contact-links {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.btn-contact {
  padding: 14px 28px;
  font-size: 0.88rem;
  font-weight: 700;
  border-radius: var(--border-radius-sm);
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: var(--transition-smooth);
}

.btn-contact:hover {
  background: var(--bg-primary);
  border-color: rgba(20, 28, 26, 0.15);
  color: var(--accent-indigo);
  transform: translateY(-3px);
}

.btn-contact.success {
  background: #E6FDF4;
  border-color: #34D399;
  color: #047857;
}

/* ==========================================================================
   11. Footer
   ========================================================================== */
footer {
  border-top: 1px solid var(--border-color);
  padding: 56px 0;
  text-align: center;
  background: var(--bg-secondary);
}

footer p {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

footer .social-icons {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 24px;
}

footer .social-icons a {
  color: var(--text-secondary);
  font-size: 1.35rem;
  transition: var(--transition-fast);
}

footer .social-icons a:hover {
  color: var(--accent-indigo);
  transform: translateY(-2px);
}

/* ==========================================================================
   12. High-Fidelity Reading Drawer Modal
   ========================================================================== */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(20, 28, 26, 0.3);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal.active {
  opacity: 1;
  pointer-events: all;
}

.modal-dialog {
  width: 90%;
  max-width: 860px;
  max-height: 90vh;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-md);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  transform: scale(0.97) translateY(30px);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.modal.active .modal-dialog {
  transform: scale(1) translateY(0);
}

.modal-header {
  padding: 36px 40px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  background: var(--bg-glass-heavy);
}

.modal-header-text {
  flex-grow: 1;
}

.modal-header-text h3 {
  font-size: 1.85rem;
  margin-bottom: 10px;
  line-height: 1.25;
  font-weight: 700;
}

.modal-meta {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.modal-close {
  font-size: 1.4rem;
  color: var(--text-secondary);
  padding: 6px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
}

.modal-close:hover {
  background: rgba(20, 28, 26, 0.04);
  color: var(--accent-indigo);
  transform: rotate(90deg);
}

.modal-body {
  padding: 40px 48px;
  overflow-y: auto;
  font-size: 1.08rem;
  line-height: 1.8;
  color: var(--text-secondary);
}

.modal-body h4 {
  font-size: 1.35rem;
  color: var(--text-primary);
  margin-top: 36px;
  margin-bottom: 16px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 700;
}

.modal-body h5 {
  font-size: 1.1rem;
  color: var(--text-primary);
  margin-top: 28px;
  margin-bottom: 12px;
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-weight: 600;
}

.modal-body p {
  margin-bottom: 24px;
}

.modal-body ul, .modal-body ol {
  margin-bottom: 24px;
}

.modal-body strong {
  color: var(--text-primary);
  font-weight: 600;
}

@media (max-width: 768px) {
  .modal-header {
    padding: 24px;
  }
  .modal-body {
    padding: 24px;
    font-size: 1rem;
  }
}

/* ==========================================================================
   13. Animations & Motion Effects
   ========================================================================== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateY(0) translateX(-50%);
  }
  40% {
    transform: translateY(-8px) translateX(-50%);
  }
  60% {
    transform: translateY(-4px) translateX(-50%);
  }
}

/* Mobile Toggle Button (hidden by default on desktop) */
.mobile-menu-toggle {
  display: none;
  font-size: 1.25rem;
  color: var(--text-primary);
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  border-radius: 4px;
  transition: var(--transition-fast);
}

.mobile-menu-toggle:hover {
  background: rgba(20, 28, 26, 0.04);
  color: var(--accent-indigo);
}

/* ==========================================================================
   14. Advanced Mobile Responsive Adjustments (Phones & Tablets)
   ========================================================================== */
@media (max-width: 768px) {
  /* Layout padding adjustments */
  .console-main .section-padding {
    padding: 70px 24px;
  }

  /* Fixed Mobile Header Console (Row layout with toggle button) */
  .console-sidebar {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 64px !important; /* Premium thin bar */
    bottom: auto !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 0 20px !important;
    z-index: 1000 !important;
    background: var(--bg-glass-heavy) !important;
    backdrop-filter: blur(28px) !important;
    -webkit-backdrop-filter: blur(28px) !important;
    border-right: none !important;
    border-bottom: 1px solid var(--border-color) !important;
    box-shadow: 0 4px 20px rgba(20, 28, 26, 0.02) !important;
  }

  /* Align brand on the left, button on the right */
  .sidebar-brand-wrapper {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    width: 100% !important;
    margin-bottom: 0 !important;
  }

  .logo-lockup {
    justify-content: flex-start !important;
    width: auto !important;
  }

  .mobile-menu-toggle {
    display: block !important;
  }

  /* Dropdown Menu styling - stacks links vertically and slides in */
  .console-nav {
    display: flex !important;
    position: absolute !important;
    top: 64px !important;
    left: 0 !important;
    width: 100% !important;
    background: var(--bg-glass-heavy) !important;
    backdrop-filter: blur(28px) !important;
    -webkit-backdrop-filter: blur(28px) !important;
    border-bottom: 1px solid var(--border-color) !important;
    padding: 16px 20px !important;
    flex-direction: column !important;
    
    /* Animation base state (closed by default) */
    opacity: 0 !important;
    pointer-events: none !important;
    transform: translateY(-12px) !important;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease !important;
  }

  /* Open state triggered via JavaScript .menu-open class */
  .console-sidebar.menu-open .console-nav {
    opacity: 1 !important;
    pointer-events: all !important;
    transform: translateY(0) !important;
  }

  .console-nav .nav-links {
    flex-direction: column !important;
    flex-wrap: nowrap !important;
    gap: 8px !important;
    width: 100% !important;
  }

  .console-nav .nav-links li {
    width: 100% !important;
    flex-shrink: 0 !important;
  }

  .console-nav .nav-links a {
    display: flex !important;
    width: 100% !important;
    padding: 12px 16px !important;
    font-size: 0.9rem !important;
    border-radius: var(--border-radius-sm) !important;
    border: 1px solid transparent !important;
    background: transparent !important;
  }

  .console-nav .nav-links a.active {
    background: var(--gradient-accent) !important;
    color: white !important;
    border-color: var(--accent-indigo) !important;
  }

  /* Clear height of fixed header console */
  .console-main {
    margin-left: 0 !important;
    width: 100% !important;
    padding-top: 84px !important; /* Matches 64px header + padding */
  }

  /* Override inline styling on biography cards to prevent horizontal squeezing */
  #about .glass-card {
    padding: 24px !important;
  }
  
  /* Hero adjustments for smaller viewports */
  .hero h1 {
    font-size: 2.1rem !important;
    letter-spacing: -0.8px;
    margin-bottom: 20px;
    line-height: 1.2;
  }
  
  .hero-subtitle {
    font-size: 1.02rem;
    line-height: 1.6;
    margin-bottom: 32px;
  }
  
  .hero-actions {
    flex-direction: column;
    gap: 12px;
    width: 100%;
  }
  
  .hero-actions .btn {
    width: 100%;
    justify-content: center;
  }
  
  /* System Card structural padding on mobile */
  .system-card-top {
    padding: 24px;
    flex-direction: column;
    gap: 16px;
  }
  
  .system-icon {
    width: 48px;
    height: 48px;
    font-size: 1.25rem;
  }

  .system-summary h3 {
    font-size: 1.15rem;
  }

  /* Publications Grid Card Padding adjustments */
  .publication-card {
    padding: 24px;
  }

  .pub-title {
    font-size: 1.2rem;
  }

  .pub-footer-links {
    flex-direction: column;
    gap: 12px;
  }

  .pub-link {
    width: 100%;
  }

  /* Blog Card Padding adjustments */
  .blog-card {
    padding: 24px;
  }

  .blog-title {
    font-size: 1.25rem;
  }
  
  /* Contact section layout */
  .contact-card {
    padding: 32px 24px;
  }

  .contact-card h3 {
    font-size: 1.65rem;
  }

  .contact-card p {
    margin-bottom: 28px;
  }

  .contact-links {
    flex-direction: column;
    gap: 12px;
    width: 100%;
  }
  
  .contact-links .btn-contact {
    width: 100%;
    justify-content: center;
  }
  
  /* Executive Badge formatting for titles on mobile */
  .timeline-content h3 {
    display: flex;
    flex-direction: column;
    gap: 6px;
    align-items: flex-start;
  }
  
  .executive-badge {
    margin-left: 0;
    margin-top: 2px;
  }
}

@media (max-width: 480px) {
  /* Shrink hero padding and titles for tight viewports */
  .console-main .hero {
    padding-top: 80px !important;
    padding-bottom: 50px;
  }

  .hero-tagline {
    font-size: 0.72rem;
    padding: 4px 10px;
    margin-bottom: 16px;
  }

  /* Double down on biography card spacing for narrow phones */
  #about .glass-card {
    padding: 20px 16px !important;
  }

  /* Tighten navigation bar elements */
  .console-nav .nav-links a {
    padding: 12px 16px !important;
    font-size: 0.85rem !important;
  }

  /* Adjust timeline padding to fit small screen widths */
  .timeline-item {
    padding-left: 36px !important;
    margin-bottom: 40px;
  }
  
  .timeline::before {
    left: 10px;
  }
  
  .timeline-badge {
    left: 4px;
    top: 6px;
  }
  
  /* Modal responsive sizing */
  .modal-dialog {
    width: 95%;
    max-height: 95vh;
    border-radius: var(--border-radius-sm);
  }

  .modal-header {
    padding: 20px;
  }

  .modal-header-text h3 {
    font-size: 1.25rem;
  }

  .modal-body {
    padding: 20px;
    font-size: 0.95rem;
    line-height: 1.7;
  }
}

