/* ==========================================================================
   VIPIN CHANDRAN A — QUANTUM AI & COMPUTER VISION PORTFOLIO
   Modern Design System (Dark & Light Themes + Responsive Bento Architecture)
   ========================================================================== */

:root,
[data-theme="dark"] {
  --bg-base: #060913;
  --bg-alt: #090e1d;
  --bg-surface: rgba(15, 23, 42, 0.68);
  --bg-surface-elevated: rgba(23, 33, 58, 0.85);
  --bg-glass: rgba(11, 17, 32, 0.78);

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

  --border-subtle: rgba(148, 163, 184, 0.14);
  --border-hover: rgba(34, 211, 238, 0.45);

  --accent-cyan: #22d3ee;
  --accent-cyan-glow: rgba(34, 211, 238, 0.18);
  --accent-indigo: #818cf8;
  --accent-indigo-glow: rgba(129, 140, 248, 0.18);
  --accent-emerald: #34d399;
  --accent-emerald-glow: rgba(52, 211, 153, 0.16);
  --accent-amber: #fbbf24;
  --accent-purple: #c084fc;

  --shadow-card: 0 20px 45px -15px rgba(2, 6, 23, 0.75);
  --shadow-glow: 0 0 32px -6px rgba(34, 211, 238, 0.28);

  --font-display: 'Space Grotesk', system-ui, -apple-system, sans-serif;
  --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 26px;

  --transition-fast: 180ms cubic-bezier(0.16, 1, 0.3, 1);
  --transition-smooth: 320ms cubic-bezier(0.16, 1, 0.3, 1);
}

[data-theme="light"] {
  --bg-base: #f8fafc;
  --bg-alt: #f1f5f9;
  --bg-surface: rgba(255, 255, 255, 0.88);
  --bg-surface-elevated: #ffffff;
  --bg-glass: rgba(255, 255, 255, 0.85);

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

  --border-subtle: rgba(15, 23, 42, 0.1);
  --border-hover: rgba(8, 145, 178, 0.45);

  --accent-cyan: #0891b2;
  --accent-cyan-glow: rgba(8, 145, 178, 0.12);
  --accent-indigo: #4f46e5;
  --accent-indigo-glow: rgba(79, 70, 229, 0.12);
  --accent-emerald: #059669;
  --accent-emerald-glow: rgba(5, 150, 105, 0.12);
  --accent-amber: #d97706;
  --accent-purple: #9333ea;

  --shadow-card: 0 14px 34px -10px rgba(15, 23, 42, 0.08);
  --shadow-glow: 0 0 25px -5px rgba(8, 145, 178, 0.2);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 90px;
  font-family: var(--font-sans);
  background-color: var(--bg-base);
  color: var(--text-primary);
}

body {
  background-color: var(--bg-base);
  color: var(--text-primary);
  line-height: 1.65;
  overflow-x: hidden;
  transition: background-color var(--transition-smooth), color var(--transition-smooth);
  position: relative;
}

a {
  color: inherit;
  text-decoration: none;
}

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

/* Ambient Background & Grid */
.ambient-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(110px);
  opacity: 0.38;
  transition: opacity var(--transition-smooth);
}

[data-theme="light"] .glow-orb {
  opacity: 0.16;
}

.orb-cyan {
  width: 520px;
  height: 520px;
  background: radial-gradient(circle, var(--accent-cyan), transparent 70%);
  top: -140px;
  left: -100px;
}

.orb-indigo {
  width: 580px;
  height: 580px;
  background: radial-gradient(circle, var(--accent-indigo), transparent 70%);
  top: 15%;
  right: -180px;
}

.orb-emerald {
  width: 460px;
  height: 460px;
  background: radial-gradient(circle, var(--accent-emerald), transparent 70%);
  bottom: 8%;
  left: 18%;
}

.grid-overlay {
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(to right, var(--border-subtle) 1px, transparent 1px),
    linear-gradient(to bottom, var(--border-subtle) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 80% 65% at 50% 25%, #000 35%, transparent 100%);
  opacity: 0.35;
}

/* Scroll Progress */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--accent-cyan), var(--accent-indigo), var(--accent-emerald));
  z-index: 1000;
  transition: width 60ms linear;
}

/* Container */
.container {
  width: 100%;
  max-width: 1220px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Header & Navigation */
.site-header {
  position: sticky;
  top: 0;
  z-index: 900;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  transition: all var(--transition-fast);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 74px;
  gap: 16px;
}

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

.logo-qubit {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 11px;
  background: linear-gradient(135deg, var(--accent-cyan-glow), var(--accent-indigo-glow));
  border: 1px solid var(--border-hover);
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--accent-cyan);
  box-shadow: var(--shadow-glow);
}

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

.brand-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.brand-tag {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link {
  padding: 7px 13px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color var(--transition-fast), background var(--transition-fast);
}

.nav-link:hover,
.nav-link.active {
  color: var(--text-primary);
  background: var(--accent-cyan-glow);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.cmd-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 0.8rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.cmd-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.cmd-shortcut {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--bg-alt);
  border: 1px solid var(--border-subtle);
}

.theme-toggle {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.theme-toggle:hover {
  border-color: var(--border-hover);
  color: var(--accent-cyan);
}

[data-theme="dark"] .icon-moon {
  display: none;
}

[data-theme="light"] .icon-sun {
  display: none;
}

.mobile-menu-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 38px;
  height: 38px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 8px;
  cursor: pointer;
}

.mobile-menu-btn span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--text-primary);
  border-radius: 2px;
}

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero-section {
  padding: 68px 0 84px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 44px;
  align-items: center;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--accent-cyan-glow);
  border: 1px solid var(--border-hover);
  font-family: var(--font-mono);
  font-size: 0.77rem;
  font-weight: 500;
  color: var(--accent-cyan);
  margin-bottom: 22px;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-emerald);
  box-shadow: 0 0 10px var(--accent-emerald);
  animation: pulseDot 2s infinite;
}

@keyframes pulseDot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.35); opacity: 0.65; }
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 4.3vw, 3.65rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

.gradient-text-cyan {
  background: linear-gradient(135deg, var(--accent-cyan), #38bdf8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.gradient-text-indigo {
  background: linear-gradient(135deg, var(--accent-indigo), var(--accent-purple));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-subtitle {
  font-size: 1.07rem;
  color: var(--text-secondary);
  max-width: 620px;
  margin-bottom: 24px;
}

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

.interest-Readout {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 30px;
}

.interest-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 12px;
  border-radius: 999px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.chip-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}
.chip-dot.cyan { background: var(--accent-cyan); }
.chip-dot.emerald { background: var(--accent-emerald); }
.chip-dot.indigo { background: var(--accent-indigo); }
.chip-dot.amber { background: var(--accent-amber); }
.chip-dot.purple { background: var(--accent-purple); }

.hero-cta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 30px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 22px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  border: 1px solid transparent;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent-cyan), var(--accent-indigo));
  color: #040711;
  box-shadow: var(--shadow-glow);
}

.btn-primary:hover {
  transform: translateY(-2px);
  filter: brightness(1.08);
}

.btn-secondary {
  background: var(--bg-surface-elevated);
  border-color: var(--border-subtle);
  color: var(--text-primary);
}

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

.btn-ghost {
  background: transparent;
  border-color: var(--border-subtle);
  color: var(--text-secondary);
}

.btn-ghost:hover {
  color: var(--text-primary);
  border-color: var(--text-secondary);
}

.btn-full {
  width: 100%;
}

.hero-meta-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  padding-top: 18px;
  border-top: 1px solid var(--border-subtle);
  font-size: 0.83rem;
  color: var(--text-muted);
}

.meta-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.meta-link:hover {
  color: var(--accent-cyan);
}

/* Hero Quantum Canvas Card */
.quantum-card {
  background: var(--bg-surface);
  backdrop-filter: blur(18px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: border-color var(--transition-smooth);
}

.quantum-card:hover {
  border-color: var(--border-hover);
}

.quantum-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 18px;
  background: rgba(2, 6, 23, 0.4);
  border-bottom: 1px solid var(--border-subtle);
}

.window-dots {
  display: flex;
  gap: 6px;
}

.window-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.window-dots span:nth-child(1) { background: #ef4444; }
.window-dots span:nth-child(2) { background: #f59e0b; }
.window-dots span:nth-child(3) { background: #10b981; }

.mono-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.live-badge {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 99px;
  background: var(--accent-cyan-glow);
  color: var(--accent-cyan);
  border: 1px solid var(--border-hover);
}

.canvas-wrapper {
  position: relative;
  height: 270px;
  background: radial-gradient(circle at center, rgba(34, 211, 238, 0.08), transparent 75%);
}

#quantumCanvas {
  width: 100%;
  height: 100%;
  display: block;
  cursor: crosshair;
}

.canvas-overlay-hud {
  position: absolute;
  bottom: 12px;
  left: 12px;
  right: 12px;
  display: flex;
  justify-content: space-between;
  gap: 8px;
  pointer-events: none;
}

.hud-metric {
  background: rgba(6, 9, 19, 0.78);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(148, 163, 184, 0.18);
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  display: flex;
  flex-direction: column;
}

.hud-key {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--accent-cyan);
  letter-spacing: 0.06em;
}

.hud-val {
  font-size: 0.73rem;
  font-weight: 600;
  color: #f8fafc;
}

.hero-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-surface-elevated);
}

.stat-box {
  padding: 16px 14px;
  text-align: center;
  border-right: 1px solid var(--border-subtle);
}

.stat-box:last-child {
  border-right: none;
}

.stat-number {
  font-family: var(--font-display);
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--accent-cyan);
  line-height: 1.15;
}

.stat-label {
  font-size: 0.73rem;
  color: var(--text-secondary);
  margin-top: 4px;
}

/* ==========================================================================
   SECTIONS & HEADINGS
   ========================================================================== */
.section {
  padding: 88px 0;
}

.section-alt {
  background: var(--bg-alt);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.section-header {
  max-width: 700px;
  margin-bottom: 48px;
}

.section-eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--accent-cyan);
  margin-bottom: 10px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 3vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.section-desc {
  color: var(--text-secondary);
  font-size: 1.02rem;
}

/* ==========================================================================
   RESEARCH EXPERIENCE CARDS
   ========================================================================== */
.research-cards {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.research-card {
  background: var(--bg-surface);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-card);
  transition: transform var(--transition-fast), border-color var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.research-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
}

.research-card.featured-emerald::before { background: var(--accent-emerald); }
.research-card.featured-cyan::before { background: var(--accent-cyan); }
.research-card.featured-indigo::before { background: var(--accent-indigo); }

.research-card:hover {
  transform: translateY(-3px);
  border-color: var(--border-hover);
}

.research-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.badge {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 11px;
  border-radius: 99px;
}

.badge-emerald {
  background: var(--accent-emerald-glow);
  color: var(--accent-emerald);
  border: 1px solid rgba(52, 211, 153, 0.35);
}

.badge-cyan {
  background: var(--accent-cyan-glow);
  color: var(--accent-cyan);
  border: 1px solid rgba(34, 211, 238, 0.35);
}

.badge-indigo {
  background: var(--accent-indigo-glow);
  color: var(--accent-indigo);
  border: 1px solid rgba(129, 140, 248, 0.35);
}

.institution-tag {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-muted);
}

.research-role {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.supervisors-note {
  font-size: 0.86rem;
  color: var(--accent-cyan);
  margin-bottom: 14px;
}

.research-summary {
  color: var(--text-secondary);
  margin: 14px 0 22px;
  font-size: 0.98rem;
}

.research-highlights {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-bottom: 24px;
}

.highlight-item {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.highlight-icon {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--accent-cyan);
  background: var(--accent-cyan-glow);
  width: fit-content;
  padding: 2px 8px;
  border-radius: 4px;
}

.highlight-item strong {
  font-size: 0.92rem;
  display: block;
  margin-bottom: 4px;
}

.highlight-item p {
  font-size: 0.84rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

.tech-stack-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tech-pill {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 4px 11px;
  border-radius: 6px;
  background: var(--bg-alt);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
}

/* ==========================================================================
   INTERACTIVE LAB SHOWCASE (QCNN & FLOODNET)
   ========================================================================== */
.lab-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.lab-panel {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.lab-panel-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.mono-tag {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  display: block;
  margin-bottom: 4px;
}
.mono-tag.cyan { color: var(--accent-cyan); }
.mono-tag.emerald { color: var(--accent-emerald); }

.lab-panel-header h3 {
  font-family: var(--font-display);
  font-size: 1.22rem;
}

.scale-toggle-group,
.arch-selector {
  display: inline-flex;
  background: var(--bg-alt);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 3px;
}

.scale-btn,
.arch-btn {
  padding: 5px 11px;
  font-size: 0.76rem;
  font-weight: 600;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  border-radius: 6px;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.scale-btn.active,
.arch-btn.active {
  background: var(--bg-surface-elevated);
  color: var(--accent-cyan);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.qview-pane {
  display: none;
}

.qview-pane.active {
  display: block;
}

.comparison-bars {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 22px;
}

.comp-row {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px;
}

.comp-label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 0.88rem;
}

.comp-model-name {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.dot-indicator {
  width: 9px;
  height: 9px;
  border-radius: 50%;
}
.dot-indicator.cyan { background: var(--accent-cyan); box-shadow: 0 0 8px var(--accent-cyan); }
.dot-indicator.muted { background: var(--text-muted); }

.comp-stat-badge {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  padding: 2px 9px;
  border-radius: 99px;
}
.comp-stat-badge.cyan {
  background: var(--accent-cyan-glow);
  color: var(--accent-cyan);
}
.comp-stat-badge.muted {
  background: var(--bg-alt);
  color: var(--text-secondary);
}

.dual-progress {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.metric-line {
  display: grid;
  grid-template-columns: 145px 1fr 90px;
  align-items: center;
  gap: 10px;
  font-size: 0.77rem;
}

.m-name {
  color: var(--text-secondary);
}

.bar-track {
  height: 8px;
  background: var(--bg-alt);
  border-radius: 99px;
  overflow: hidden;
}

.bar-fill {
  height: 100%;
  border-radius: 99px;
  transition: width 600ms cubic-bezier(0.16, 1, 0.3, 1);
}
.fill-cyan { background: linear-gradient(90deg, var(--accent-cyan), var(--accent-indigo)); }
.fill-emerald { background: var(--accent-emerald); }
.fill-muted { background: var(--text-muted); }
.fill-amber { background: linear-gradient(90deg, #f59e0b, #ef4444); }

.m-val {
  font-family: var(--font-mono);
  text-align: right;
  font-weight: 600;
}

.efficiency-callout {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 16px;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, var(--accent-cyan-glow), var(--accent-indigo-glow));
  border: 1px solid var(--border-hover);
}

.eff-number {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent-cyan);
  white-space: nowrap;
}

.eff-text strong {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 3px;
}

.eff-text p {
  font-size: 0.81rem;
  color: var(--text-secondary);
}

/* Circuit Pipeline Steps */
.pipeline-steps {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr;
  gap: 8px;
  align-items: stretch;
  margin-top: 10px;
}

.pipe-node {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.pipe-node.highlight-node {
  border-color: var(--accent-cyan);
  background: var(--accent-cyan-glow);
}

.pipe-step-num {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--accent-cyan);
}

.pipe-node strong {
  font-size: 0.85rem;
}

.pipe-node code {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--accent-emerald);
}

.pipe-node p {
  font-size: 0.76rem;
  color: var(--text-secondary);
  line-height: 1.45;
}

.pipe-arrow {
  display: flex;
  align-items: center;
  color: var(--accent-cyan);
  font-weight: 700;
}

/* FloodNet UAV Simulator */
.uav-viewport {
  position: relative;
  height: 175px;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  margin-bottom: 16px;
  background: #07111e;
}

.uav-grid-map {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  grid-template-rows: 1fr 1fr;
  height: 100%;
  gap: 4px;
  padding: 6px;
}

.uav-zone {
  border-radius: 8px;
  display: flex;
  align-items: flex-end;
  padding: 10px 12px;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  font-weight: 600;
  color: #fff;
  transition: all var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.zone-water {
  background: linear-gradient(135deg, rgba(14, 165, 233, 0.55), rgba(2, 132, 199, 0.3));
  border: 1px solid rgba(56, 189, 248, 0.6);
}

.zone-road {
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.5), rgba(217, 119, 6, 0.25));
  border: 1px solid rgba(251, 191, 36, 0.6);
}

.zone-building {
  background: linear-gradient(135deg, rgba(236, 72, 153, 0.45), rgba(139, 92, 246, 0.45));
  background-color: rgba(139, 92, 246, 0.35);
  border: 1px solid rgba(167, 139, 250, 0.6);
}

.zone-veg {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.5), rgba(5, 150, 105, 0.25));
  border: 1px solid rgba(52, 211, 153, 0.6);
}

.uav-zone.dimmed {
  opacity: 0.2;
  filter: grayscale(0.7);
}

.uav-scanline {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent-emerald), transparent);
  box-shadow: 0 0 12px var(--accent-emerald);
  animation: scanUAV 3.6s ease-in-out infinite;
  pointer-events: none;
}

@keyframes scanUAV {
  0%, 100% { top: 4%; }
  50% { top: 94%; }
}

.arch-info-card {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  margin-bottom: 14px;
}

.arch-badge-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 6px;
}

.arch-name {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--accent-emerald);
}

.arch-focus {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
}

#archDescription {
  font-size: 0.83rem;
  color: var(--text-secondary);
}

.class-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.legend-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 11px;
  border-radius: 99px;
  background: var(--bg-alt);
  border: 1px solid var(--border-subtle);
  font-size: 0.75rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.legend-chip.active,
.legend-chip:hover {
  border-color: var(--accent-emerald);
  color: var(--text-primary);
}

.l-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}
.l-dot.water { background: #38bdf8; }
.l-dot.road { background: #fbbf24; }
.l-dot.building { background: #a78bfa; }
.l-dot.veg { background: #34d399; }

/* ==========================================================================
   PROJECTS BENTO GRID & FILTER
   ========================================================================== */
.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 32px;
}

.filter-btn {
  padding: 8px 16px;
  border-radius: 99px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--accent-cyan-glow);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.project-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 26px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-card);
}

.project-card.hidden {
  display: none;
}

.project-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-hover);
}

.project-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.project-domain {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 99px;
}

.project-domain.robotics { background: rgba(251, 191, 36, 0.14); color: var(--accent-amber); }
.project-domain.cv-ai { background: var(--accent-indigo-glow); color: var(--accent-indigo); }
.project-domain.quantum { background: var(--accent-cyan-glow); color: var(--accent-cyan); }
.project-domain.ml-data { background: var(--accent-emerald-glow); color: var(--accent-emerald); }

.project-index {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
}

.project-title {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 10px;
  line-height: 1.3;
}

.project-excerpt {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-bottom: 18px;
  flex-grow: 1;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 20px;
}

.project-tags span {
  font-family: var(--font-mono);
  font-size: 0.71rem;
  padding: 3px 9px;
  border-radius: 5px;
  background: var(--bg-alt);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
}

.project-inspect-btn {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.project-inspect-btn:hover {
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
}

/* ==========================================================================
   TECHNICAL SKILLS BENTO
   ========================================================================== */
.skills-bento {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.skill-cluster {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow-card);
}

.cluster-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}

.cluster-icon {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 1.05rem;
}
.cluster-icon.cyan { background: var(--accent-cyan-glow); color: var(--accent-cyan); }
.cluster-icon.indigo { background: var(--accent-indigo-glow); color: var(--accent-indigo); }
.cluster-icon.emerald { background: var(--accent-emerald-glow); color: var(--accent-emerald); }
.cluster-icon.amber { background: rgba(251, 191, 36, 0.14); color: var(--accent-amber); }

.cluster-header h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
}

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

.skill-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
}

.skill-tag {
  padding: 6px 13px;
  border-radius: 8px;
  font-size: 0.83rem;
  font-weight: 500;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  transition: all var(--transition-fast);
}

.skill-tag.primary {
  border-color: var(--border-hover);
  color: var(--text-primary);
  font-weight: 600;
}

.skill-tag:hover {
  transform: translateY(-2px);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
}

/* ==========================================================================
   EDUCATION TIMELINE & CERTIFICATIONS
   ========================================================================== */
.edu-cert-layout {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 40px;
}

.col-heading {
  font-family: var(--font-display);
  font-size: 1.3rem;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.timeline {
  position: relative;
  padding-left: 26px;
  border-left: 2px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.timeline-item {
  position: relative;
}

.timeline-marker {
  position: absolute;
  left: -33px;
  top: 6px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--bg-base);
  border: 2px solid var(--text-muted);
}

.timeline-marker.active {
  background: var(--accent-cyan);
  border-color: var(--accent-cyan);
  box-shadow: 0 0 12px var(--accent-cyan);
}

.timeline-content {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px;
}

.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.timeline-date {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--accent-cyan);
  font-weight: 600;
}

.timeline-status,
.timeline-score {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  padding: 2px 8px;
  border-radius: 99px;
  background: var(--bg-alt);
  color: var(--text-secondary);
}

.timeline-score {
  color: var(--accent-emerald);
  background: var(--accent-emerald-glow);
}

.timeline-content h4 {
  font-family: var(--font-display);
  font-size: 1.12rem;
  margin-bottom: 4px;
}

.timeline-inst {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.timeline-detail {
  font-size: 0.86rem;
  color: var(--text-secondary);
}

/* Certifications Column */
.certs-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.cert-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  transition: border-color var(--transition-fast);
}

.cert-card:hover {
  border-color: var(--border-hover);
}

.cert-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--accent-indigo-glow);
  color: var(--accent-indigo);
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 0.82rem;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.cert-body {
  flex-grow: 1;
}

.cert-body h4 {
  font-size: 0.95rem;
  font-weight: 600;
}

.cert-body p {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.cert-badge {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  padding: 3px 9px;
  border-radius: 99px;
  background: var(--bg-alt);
  color: var(--text-secondary);
  white-space: nowrap;
}

.cert-badge.highlight {
  background: var(--accent-emerald-glow);
  color: var(--accent-emerald);
  font-weight: 600;
}

/* ==========================================================================
   HONOURS & LEADERSHIP
   ========================================================================== */
.honours-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.honour-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow-card);
}

.honour-card.highlight-gold {
  border-color: rgba(251, 191, 36, 0.45);
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.08), var(--bg-surface));
}

.honour-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.honour-tag {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--accent-amber);
}

.honour-year {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
}

.honour-card h3 {
  font-family: var(--font-display);
  font-size: 1.18rem;
  margin-bottom: 10px;
}

.honour-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* ==========================================================================
   CONTACT SECTION
   ========================================================================== */
.contact-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 44px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 44px;
  box-shadow: var(--shadow-card);
}

.contact-lead {
  color: var(--text-secondary);
  margin-bottom: 28px;
}

.contact-methods {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
}

.c-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--accent-cyan-glow);
  color: var(--accent-cyan);
  font-family: var(--font-mono);
  font-weight: 700;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.c-details {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  min-width: 0;
}

.c-label {
  font-size: 0.74rem;
  color: var(--text-muted);
}

.c-value {
  font-size: 0.9rem;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
}

.copy-btn {
  padding: 5px 11px;
  border-radius: 6px;
  background: var(--bg-alt);
  border: 1px solid var(--border-subtle);
  font-family: var(--font-mono);
  font-size: 0.73rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.copy-btn:hover {
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
}

/* Contact Form */
.contact-form {
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 28px;
}

.contact-form h3 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  margin-bottom: 18px;
}

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

.form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 10px 13px;
  border-radius: var(--radius-sm);
  background: var(--bg-base);
  border: 1px solid var(--border-subtle);
  font-size: 0.9rem;
  transition: border-color var(--transition-fast);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent-cyan);
}

.form-Status {
  margin-top: 10px;
  font-size: 0.82rem;
  color: var(--accent-emerald);
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 32px 0;
  background: var(--bg-alt);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-left p {
  font-size: 0.8rem;
  margin-top: 2px;
}

.footer-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

kbd {
  font-family: var(--font-mono);
  font-size: 0.73rem;
  padding: 2px 6px;
  border-radius: 4px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
}

.back-to-top:hover {
  color: var(--accent-cyan);
}

/* ==========================================================================
   MODALS (<dialog>) & TOAST
   ========================================================================== */
dialog {
  margin: auto;
  border: 1px solid var(--border-hover);
  border-radius: var(--radius-lg);
  background: var(--bg-surface-elevated);
  color: var(--text-primary);
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.75);
  max-width: 620px;
  width: calc(100% - 32px);
  padding: 0;
}

dialog::backdrop {
  background: rgba(2, 6, 23, 0.72);
  backdrop-filter: blur(6px);
}

.modal-inner {
  padding: 28px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.modal-badge {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--accent-cyan);
  background: var(--accent-cyan-glow);
  padding: 4px 10px;
  border-radius: 99px;
}

.modal-close {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 1px solid var(--border-subtle);
  background: var(--bg-alt);
  cursor: pointer;
}

.modal-title {
  font-family: var(--font-display);
  font-size: 1.4rem;
  margin-bottom: 6px;
}

.modal-subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 18px;
}

.modal-body {
  font-size: 0.93rem;
  color: var(--text-secondary);
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

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

/* Command Palette */
.cmd-modal {
  max-width: 560px;
}

.cmd-inner {
  overflow: hidden;
}

.cmd-search-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border-subtle);
}

.cmd-search-bar input {
  flex-grow: 1;
  background: transparent;
  border: none;
  font-size: 0.95rem;
  outline: none;
}

.esc-hint {
  cursor: pointer;
}

.cmd-list {
  max-height: 320px;
  overflow-y: auto;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cmd-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: none;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: background var(--transition-fast);
}

.cmd-item:hover,
.cmd-item:focus {
  background: var(--accent-cyan-glow);
  outline: none;
}

.cmd-item-title {
  font-size: 0.88rem;
  font-weight: 600;
}

.cmd-item-meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* Toast */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  padding: 12px 18px;
  border-radius: var(--radius-md);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--accent-cyan);
  color: var(--text-primary);
  font-size: 0.86rem;
  font-weight: 600;
  box-shadow: var(--shadow-card);
  transform: translateY(120%);
  opacity: 0;
  transition: all var(--transition-smooth);
  z-index: 1100;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

/* Scroll Reveal Animation */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 550ms ease, transform 550ms cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   RESPONSIVE BREAKPOINTS
   ========================================================================== */
@media (max-width: 1040px) {
  .hero-grid,
  .lab-grid,
  .edu-cert-layout,
  .contact-card {
    grid-template-columns: 1fr;
  }

  .research-highlights,
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .pipeline-steps {
    grid-template-columns: 1fr;
  }

  .pipe-arrow {
    display: none;
  }
}

@media (max-width: 768px) {
  .main-nav {
    position: fixed;
    top: 74px;
    left: 0;
    right: 0;
    background: var(--bg-surface-elevated);
    border-bottom: 1px solid var(--border-subtle);
    flex-direction: column;
    padding: 16px;
    display: none;
  }

  .main-nav.open {
    display: flex;
  }

  .mobile-menu-btn {
    display: flex;
  }

  .research-highlights,
  .projects-grid,
  .skills-bento,
  .honours-grid {
    grid-template-columns: 1fr;
  }

  .metric-line {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .contact-card {
    padding: 24px;
  }
}

/* Print-friendly Academic CV formatting */
@media print {
  .site-header,
  .ambient-bg,
  .scroll-progress,
  .hero-visual,
  .hero-cta-group,
  .filter-bar,
  .project-inspect-btn,
  .contact-form,
  .site-footer {
    display: none !important;
  }

  body {
    background: #fff !important;
    color: #000 !important;
  }

  .section {
    padding: 24px 0 !important;
  }

  .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}
