/* ==========================================================================
   Nguyen Danh Huy — Portfolio Stylesheet
   Theme: High-End Dark Tech, Glassmorphism, Electric Cyan & Violet Accents
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. CSS Custom Properties & Design Tokens
   -------------------------------------------------------------------------- */
:root {
  /* Color Palette */
  --bg-dark: #070a12;
  --bg-card: rgba(15, 23, 42, 0.72);
  --bg-card-hover: rgba(24, 34, 61, 0.85);
  --bg-alt: #0a0f1d;
  --bg-input: rgba(15, 23, 42, 0.9);
  
  /* Text Colors */
  --text-main: #f1f5f9;
  --text-muted: #94a3b8;
  --text-dim: #64748b;
  
  /* Accent Gradients & Colors */
  --accent-cyan: #06b6d4;
  --accent-blue: #3b82f6;
  --accent-violet: #8b5cf6;
  --accent-emerald: #10b981;
  --accent-amber: #f59e0b;
  --accent-rose: #f43f5e;
  
  --gradient-primary: linear-gradient(135deg, #06b6d4 0%, #3b82f6 50%, #8b5cf6 100%);
  --gradient-accent: linear-gradient(135deg, #8b5cf6 0%, #d946ef 100%);
  --gradient-glow: radial-gradient(circle, rgba(6, 182, 212, 0.15) 0%, rgba(139, 92, 246, 0.05) 50%, transparent 70%);

  /* Borders & Shadows */
  --border-subtle: rgba(255, 255, 255, 0.08);
  --border-highlight: rgba(6, 182, 212, 0.35);
  --border-violet: rgba(139, 92, 246, 0.35);
  --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.6);
  --shadow-glow: 0 0 25px rgba(6, 182, 212, 0.2);

  /* Typography */
  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', SFMono-Regular, Menlo, Monaco, Consolas, monospace;

  /* Layout */
  --container-max: 1200px;
  --nav-height: 72px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-pill: 9999px;

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-slow: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-height) + 24px);
  font-size: 16px;
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: var(--font-sans);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  line-height: 1.6;
  overflow-x: hidden;
  background-color: var(--bg-dark);
  position: relative;
  min-height: 100vh;
}

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

button {
  cursor: pointer;
  border: none;
  background: none;
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

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

.code-font {
  font-family: var(--font-mono);
}

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 24px;
}

/* --------------------------------------------------------------------------
   3. Ambient Glowing Background Orbs
   -------------------------------------------------------------------------- */
.ambient-glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(140px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.45;
  animation: floatOrb 20s infinite alternate ease-in-out;
}

.glow-1 {
  width: 550px;
  height: 550px;
  top: -100px;
  left: -150px;
  background: radial-gradient(circle, rgba(6, 182, 212, 0.45), transparent 70%);
}

.glow-2 {
  width: 650px;
  height: 650px;
  top: 35%;
  right: -200px;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.35), transparent 70%);
  animation-duration: 25s;
  animation-delay: -5s;
}

.glow-3 {
  width: 500px;
  height: 500px;
  bottom: 5%;
  left: 15%;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.25), transparent 70%);
  animation-duration: 22s;
  animation-delay: -10s;
}

@keyframes floatOrb {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(60px, 40px) scale(1.08); }
  100% { transform: translate(-40px, 60px) scale(0.95); }
}

/* --------------------------------------------------------------------------
   4. Typography Utilities & Text Gradient
   -------------------------------------------------------------------------- */
.text-gradient {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
}

.section-tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 14px;
  background: rgba(6, 182, 212, 0.12);
  color: var(--accent-cyan);
  border: 1px solid rgba(6, 182, 212, 0.25);
  border-radius: var(--radius-pill);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.section-header {
  text-align: center;
  max-width: 760px;
  margin: 0 auto 52px;
}

.section-title {
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #fff;
  margin-bottom: 14px;
}

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

.section {
  position: relative;
  z-index: 1;
  padding: 100px 0;
}

.section.bg-alt {
  background: linear-gradient(180deg, rgba(10, 15, 29, 0.6) 0%, rgba(7, 10, 18, 0.9) 100%);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

/* --------------------------------------------------------------------------
   5. Buttons & Pills
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 0.92rem;
  transition: all var(--transition-normal);
  white-space: nowrap;
}

.btn-sm {
  padding: 8px 16px;
  font-size: 0.84rem;
}

.btn-lg {
  padding: 14px 32px;
  font-size: 1rem;
}

.btn-primary {
  background: var(--gradient-primary);
  color: #fff;
  box-shadow: 0 4px 20px rgba(6, 182, 212, 0.35);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(6, 182, 212, 0.55);
  filter: brightness(1.1);
}

.btn-secondary {
  background: rgba(139, 92, 246, 0.15);
  color: #c4b5fd;
  border: 1px solid rgba(139, 92, 246, 0.35);
}

.btn-secondary:hover {
  background: rgba(139, 92, 246, 0.25);
  border-color: rgba(139, 92, 246, 0.6);
  color: #fff;
  transform: translateY(-2px);
}

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

.btn-outline:hover {
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.08);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

/* --------------------------------------------------------------------------
   6. Header & Navigation
   -------------------------------------------------------------------------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  z-index: 100;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  background: rgba(7, 10, 18, 0.8);
  border-bottom: 1px solid var(--border-subtle);
  transition: all var(--transition-normal);
}

.site-header.scrolled {
  background: rgba(7, 10, 18, 0.95);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 1.18rem;
  letter-spacing: -0.01em;
}

.logo-symbol {
  font-family: var(--font-mono);
  color: var(--accent-cyan);
  font-weight: 800;
  background: rgba(6, 182, 212, 0.12);
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(6, 182, 212, 0.25);
}

.logo-name strong {
  color: var(--accent-violet);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-muted);
  position: relative;
  padding: 6px 0;
}

.nav-link:hover,
.nav-link.active {
  color: #fff;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0%;
  height: 2px;
  background: var(--gradient-primary);
  border-radius: 2px;
  transition: width var(--transition-normal);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}

.mobile-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background-color: var(--text-main);
  border-radius: 2px;
  transition: var(--transition-fast);
}

/* --------------------------------------------------------------------------
   7. Hero Section
   -------------------------------------------------------------------------- */
.hero-section {
  position: relative;
  z-index: 1;
  padding: calc(var(--nav-height) + 60px) 0 80px;
  overflow: hidden;
}

.hero-container {
  display: grid;
  grid-template-columns: 1.2fr 0.95fr;
  align-items: center;
  gap: 48px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-radius: var(--radius-pill);
  color: #34d399;
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 24px;
}

.status-dot {
  width: 8px;
  height: 8px;
  background-color: #10b981;
  border-radius: 50%;
  box-shadow: 0 0 10px #10b981;
  animation: pulseDot 2s infinite ease-in-out;
}

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

.hero-title {
  font-size: clamp(2.5rem, 5vw, 3.8rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.03em;
  margin-bottom: 18px;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: #e2e8f0;
  margin-bottom: 16px;
  font-weight: 400;
}

.hero-subtitle strong {
  color: #fff;
}

.hero-desc {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 580px;
  line-height: 1.7;
  margin-bottom: 32px;
}

.hero-desc strong {
  color: #e2e8f0;
}

.hero-cta-group {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 36px;
}

.hero-contact-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 24px;
  border-top: 1px solid var(--border-subtle);
}

.contact-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.84rem;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-subtle);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
}

/* Terminal Card */
.terminal-card {
  background: rgba(13, 17, 28, 0.95);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card), 0 0 30px rgba(6, 182, 212, 0.1);
  overflow: hidden;
  backdrop-filter: blur(16px);
}

.terminal-header {
  background: rgba(20, 27, 45, 0.95);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--border-subtle);
}

.terminal-dots {
  display: flex;
  gap: 6px;
  margin-right: 16px;
}

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

.dot.red { background: #ef4444; }
.dot.yellow { background: #f59e0b; }
.dot.green { background: #10b981; }

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

.terminal-body {
  padding: 20px;
  font-size: 0.82rem;
  line-height: 1.6;
}

.term-line {
  margin-bottom: 8px;
}

.term-line .prompt {
  color: var(--accent-cyan);
  font-weight: 700;
  margin-right: 6px;
}

.term-line .cmd {
  color: #f8fafc;
}

.term-output pre {
  color: #cbd5e1;
  font-family: inherit;
  margin-bottom: 14px;
  background: rgba(7, 10, 18, 0.6);
  padding: 12px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.04);
}

.json-key { color: #38bdf8; }
.json-val { color: #a7f3d0; }
.json-num { color: #fbbf24; }

.term-status {
  padding-top: 6px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.status-tag.active {
  color: #34d399;
  font-weight: 700;
}

/* --------------------------------------------------------------------------
   8. Impact Metrics Strip
   -------------------------------------------------------------------------- */
.metrics-strip {
  position: relative;
  z-index: 2;
  margin-top: -20px;
  padding-bottom: 40px;
}

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.metric-card {
  background: rgba(15, 23, 42, 0.65);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 24px 20px;
  text-align: center;
  backdrop-filter: blur(12px);
  transition: transform var(--transition-normal), border-color var(--transition-normal);
}

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

.metric-number {
  font-size: 2.4rem;
  font-weight: 800;
  font-family: var(--font-mono);
  letter-spacing: -0.03em;
  margin-bottom: 6px;
}

.metric-label {
  font-weight: 700;
  font-size: 0.95rem;
  color: #fff;
  margin-bottom: 4px;
}

.metric-sub {
  font-size: 0.78rem;
  color: var(--text-dim);
}

/* --------------------------------------------------------------------------
   9. About & Objectives
   -------------------------------------------------------------------------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}

.glow-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 36px;
  backdrop-filter: blur(16px);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.glow-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gradient-primary);
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.glow-card:hover {
  border-color: rgba(6, 182, 212, 0.3);
  transform: translateY(-4px);
  box-shadow: var(--shadow-card);
}

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

.about-icon-badge {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: rgba(6, 182, 212, 0.12);
  color: var(--accent-cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  border: 1px solid rgba(6, 182, 212, 0.25);
}

.about-card h3 {
  font-size: 1.45rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 8px;
}

.role-badge {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--accent-violet);
  background: rgba(139, 92, 246, 0.12);
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  margin-bottom: 18px;
  border: 1px solid rgba(139, 92, 246, 0.25);
}

.about-card p {
  color: var(--text-muted);
  line-height: 1.7;
  font-size: 0.98rem;
  margin-bottom: 14px;
}

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

.bullet-list li {
  position: relative;
  padding-left: 20px;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.bullet-list li::before {
  content: '▹';
  position: absolute;
  left: 0;
  color: var(--accent-cyan);
  font-size: 1rem;
}

/* --------------------------------------------------------------------------
   10. Skills Section
   -------------------------------------------------------------------------- */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.skill-category-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 30px;
  backdrop-filter: blur(14px);
  transition: all var(--transition-normal);
}

.skill-category-card:hover {
  border-color: rgba(6, 182, 212, 0.3);
  transform: translateY(-3px);
}

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

.skill-cat-icon {
  font-size: 1.8rem;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.04);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
}

.skill-cat-header h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
}

.skill-cat-subtitle {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent-cyan);
  font-weight: 600;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.tech-tag {
  display: inline-flex;
  align-items: center;
  padding: 5px 12px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  font-family: var(--font-mono);
  color: #cbd5e1;
  transition: all var(--transition-fast);
}

.tech-tag:hover {
  border-color: var(--accent-cyan);
  color: #fff;
  background: rgba(6, 182, 212, 0.1);
}

.tech-tag.highlight {
  background: rgba(6, 182, 212, 0.12);
  border-color: rgba(6, 182, 212, 0.3);
  color: #38bdf8;
  font-weight: 600;
}

.skill-cat-note {
  font-size: 0.88rem;
  color: var(--text-dim);
  border-top: 1px solid var(--border-subtle);
  padding-top: 14px;
  line-height: 1.6;
}

/* --------------------------------------------------------------------------
   11. Projects Showcase
   -------------------------------------------------------------------------- */
.project-filter-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 40px;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 8px 20px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-size: 0.88rem;
  font-weight: 600;
  transition: all var(--transition-fast);
}

.filter-btn:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.2);
}

.filter-btn.active {
  background: var(--gradient-primary);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 4px 15px rgba(6, 182, 212, 0.3);
}

.projects-container {
  display: flex;
  flex-direction: column;
  gap: 36px;
}

.project-card {
  position: relative;
}

.project-ribbon {
  position: absolute;
  top: 16px;
  right: 24px;
  background: rgba(6, 182, 212, 0.18);
  color: #38bdf8;
  border: 1px solid rgba(6, 182, 212, 0.35);
  padding: 4px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.project-ribbon.secondary {
  background: rgba(139, 92, 246, 0.18);
  color: #c4b5fd;
  border-color: rgba(139, 92, 246, 0.35);
}

.project-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 20px;
  padding-right: 180px; /* Space for ribbon */
}

.project-date {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--accent-cyan);
  font-weight: 600;
  display: block;
  margin-bottom: 6px;
}

.project-title {
  font-size: 1.65rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.02em;
  line-height: 1.25;
  margin-bottom: 8px;
}

.project-role-tag {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.project-links {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.project-overview {
  font-size: 1.02rem;
  color: #cbd5e1;
  line-height: 1.7;
  margin-bottom: 22px;
}

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

.project-highlights-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-bottom: 28px;
}

.highlight-box {
  background: rgba(11, 16, 29, 0.75);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 20px;
}

.highlight-title {
  margin-bottom: 10px;
}

.highlight-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent-violet);
  background: rgba(139, 92, 246, 0.12);
  padding: 2px 8px;
  border-radius: 4px;
  margin-bottom: 6px;
}

.highlight-box h4 {
  font-size: 1.05rem;
  color: #fff;
  font-weight: 700;
}

.highlight-box p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ==========================================================================
   CareBridge Omnichannel Multi-Role Gallery
   ========================================================================== */
.carebridge-gallery-section {
  margin-top: 24px;
  padding-top: 28px;
  border-top: 1px solid var(--border-subtle);
}

.gallery-header-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 20px;
}

.gallery-title-wrap {
  flex: 1;
}

.gallery-tag {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent-cyan);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-family: var(--font-mono);
  margin-bottom: 4px;
}

.gallery-heading {
  font-size: 1.25rem;
  font-weight: 750;
  color: #fff;
  margin-bottom: 6px;
}

.gallery-sub {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.55;
  max-width: 820px;
}

.gallery-stats-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.25);
  border-radius: var(--radius-pill);
  padding: 6px 14px;
  font-size: 0.8rem;
  font-weight: 650;
  color: var(--accent-cyan);
  white-space: nowrap;
  flex-shrink: 0;
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 10px #10b981;
  animation: pulseDot 2s infinite ease-in-out;
}

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

/* Role Filter Tabs */
.gallery-role-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
}

.role-tab-btn {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-pill);
  color: var(--text-muted);
  padding: 7px 15px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.role-tab-btn:hover {
  background: rgba(30, 41, 59, 0.9);
  border-color: rgba(6, 182, 212, 0.4);
  color: #fff;
  transform: translateY(-1px);
}

.role-tab-btn.active {
  background: rgba(6, 182, 212, 0.16);
  border-color: var(--accent-cyan);
  color: #fff;
  box-shadow: 0 0 14px rgba(6, 182, 212, 0.22);
}

.role-tab-btn .tab-count {
  font-size: 0.74rem;
  opacity: 0.75;
  font-family: var(--font-mono);
}

/* Gallery Bento Grid with Alternating Orientations */
.gallery-cards-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  grid-auto-flow: dense;
  gap: 16px;
  align-items: stretch;
}

.gallery-card {
  background: rgba(11, 16, 29, 0.92);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-normal), border-color var(--transition-normal), box-shadow var(--transition-normal);
  position: relative;
  outline: none;
}

.gallery-card:hover, .gallery-card:focus-visible {
  transform: translateY(-5px);
  border-color: var(--accent-cyan);
  box-shadow: 0 14px 30px -8px rgba(6, 182, 212, 0.35);
}

/* Portrait Mobile Cards (1 Column) */
.gallery-card.portrait-card {
  grid-column: span 1;
}

.gallery-card.portrait-card .gallery-card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 9 / 16;
  background: #030712;
  overflow: hidden;
}

.gallery-card.portrait-card .gallery-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform var(--transition-slow);
}

/* Landscape Desktop Web & Blueprint Cards (2 Columns) */
.gallery-card.landscape-card {
  grid-column: span 2;
}

.gallery-card.landscape-card .gallery-card-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  background: #030712;
  overflow: hidden;
}

.gallery-card.landscape-card .gallery-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform var(--transition-slow);
}

.gallery-card.landscape-card.wide-blueprint .gallery-card-thumb {
  aspect-ratio: 16 / 9;
}

.gallery-card.landscape-card.wide-blueprint .gallery-card-thumb img {
  object-position: center center;
}

.gallery-card:hover .gallery-card-thumb img {
  transform: scale(1.04);
}

.gallery-card-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(3, 7, 18, 0.88);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-pill);
  padding: 3px 8px;
  font-size: 0.64rem;
  font-weight: 700;
  color: #38bdf8;
  font-family: var(--font-mono);
  z-index: 2;
  white-space: nowrap;
}

/* Device Pill (Bottom Left of Thumbnail) */
.gallery-card-device {
  position: absolute;
  bottom: 8px;
  left: 8px;
  background: rgba(3, 7, 18, 0.86);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-pill);
  padding: 3px 9px;
  font-size: 0.65rem;
  font-weight: 600;
  color: #e2e8f0;
  font-family: var(--font-mono);
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  letter-spacing: 0.02em;
}

.gallery-card-device .device-icon {
  font-size: 0.76rem;
}

.gallery-zoom-overlay {
  position: absolute;
  inset: 0;
  background: rgba(3, 7, 18, 0.65);
  backdrop-filter: blur(2px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  opacity: 0;
  transition: opacity var(--transition-fast);
  z-index: 3;
}

.gallery-card:hover .gallery-zoom-overlay {
  opacity: 1;
}

.zoom-icon-circle {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--accent-cyan);
  color: #030712;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 16px rgba(6, 182, 212, 0.6);
  transform: scale(0.85);
  transition: transform var(--transition-fast);
}

.gallery-card:hover .zoom-icon-circle {
  transform: scale(1);
}

.gallery-zoom-overlay span {
  font-size: 0.74rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.02em;
}

.gallery-card-meta {
  padding: 11px 12px 13px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: rgba(15, 23, 42, 0.92);
  flex: 1;
}

.gallery-card-role {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--accent-violet);
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.gallery-card-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Expander Button Container */
.gallery-expand-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-top: 22px;
  padding-top: 8px;
}

.btn-expand-gallery {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 28px;
  font-size: 0.92rem;
  font-weight: 700;
  border-radius: var(--radius-pill);
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(6, 182, 212, 0.4);
  color: #fff;
  transition: all var(--transition-normal);
  cursor: pointer;
}

.btn-expand-gallery:hover {
  background: rgba(6, 182, 212, 0.16);
  border-color: var(--accent-cyan);
  box-shadow: 0 0 24px rgba(6, 182, 212, 0.35);
  transform: translateY(-2px);
}

.expand-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent-cyan);
  color: #030712;
  font-size: 1.15rem;
  font-weight: 850;
  line-height: 1;
  transition: transform var(--transition-fast);
}

.gallery-hint {
  font-size: 0.78rem;
  color: var(--text-dim);
}

/* --------------------------------------------------------------------------
   12. System Architecture Blueprint
   -------------------------------------------------------------------------- */
.arch-showcase-card {
  padding: 36px;
}

.arch-image-wrapper {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  margin-bottom: 32px;
  cursor: pointer;
  background: #000;
}

.arch-full-image {
  width: 100%;
  max-height: 480px;
  object-fit: contain;
  background-color: #0d111c;
  transition: transform var(--transition-slow);
}

.arch-image-wrapper:hover .arch-full-image {
  transform: scale(1.015);
}

.arch-image-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-normal);
}

.arch-image-overlay span {
  background: rgba(15, 23, 42, 0.9);
  color: #fff;
  padding: 10px 24px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 0.9rem;
  border: 1px solid var(--accent-cyan);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
}

.arch-image-wrapper:hover .arch-image-overlay {
  opacity: 1;
}

.arch-layer-breakdown {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.arch-layer-item {
  display: flex;
  gap: 14px;
}

.layer-number {
  font-family: var(--font-mono);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--accent-cyan);
  line-height: 1;
  padding-top: 2px;
}

.layer-content h4 {
  font-size: 0.98rem;
  color: #fff;
  font-weight: 700;
  margin-bottom: 6px;
}

.layer-content p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* --------------------------------------------------------------------------
   13. Experience & Education Timeline
   -------------------------------------------------------------------------- */
.timeline-container {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 36px;
}

.timeline-item {
  padding: 30px;
  position: relative;
}

.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
  flex-wrap: wrap;
  gap: 12px;
}

.timeline-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 2px 10px;
  border-radius: var(--radius-pill);
  margin-bottom: 8px;
}

.timeline-badge.work {
  background: rgba(16, 185, 129, 0.12);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.timeline-badge.edu {
  background: rgba(59, 130, 246, 0.12);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.timeline-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: #fff;
}

.timeline-role {
  font-size: 1rem;
  color: var(--accent-cyan);
  font-weight: 600;
}

.timeline-period {
  font-family: var(--font-mono);
  font-size: 0.86rem;
  color: var(--text-dim);
  background: rgba(255, 255, 255, 0.04);
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-subtle);
}

.timeline-body p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 12px;
}


/* Reference Card */
.reference-card {
  padding: 30px;
  border-left: 4px solid var(--accent-cyan);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.ref-header {
  display: flex;
  align-items: center;
  gap: 16px;
}

.ref-icon {
  font-size: 2rem;
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(6, 182, 212, 0.12);
  border-radius: var(--radius-md);
  border: 1px solid rgba(6, 182, 212, 0.25);
}

.ref-label {
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent-cyan);
  font-weight: 700;
  display: block;
}

.ref-name {
  font-size: 1.25rem;
  color: #fff;
  font-weight: 700;
  margin-bottom: 2px;
}

.ref-title {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.ref-contacts {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ref-contact-item {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.ref-contact-item .label {
  color: var(--text-dim);
  margin-right: 6px;
}

.ref-contact-item .link {
  color: var(--accent-cyan);
}

.ref-contact-item .link:hover {
  text-decoration: underline;
}

.ref-contact-item .phone-val {
  font-family: var(--font-mono);
  color: #e2e8f0;
}

/* --------------------------------------------------------------------------
   14. Contact Section
   -------------------------------------------------------------------------- */
.contact-box {
  padding: 48px;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 40px;
  align-items: center;
}

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

.contact-method-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: rgba(11, 16, 29, 0.7);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  cursor: pointer;
}

.contact-method-card:hover {
  border-color: rgba(6, 182, 212, 0.35);
  transform: translateX(4px);
}

.contact-icon {
  font-size: 1.4rem;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.04);
  border-radius: var(--radius-sm);
}

.contact-info {
  flex: 1;
}

.contact-label {
  display: block;
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-dim);
}

.contact-val {
  font-size: 0.95rem;
  font-weight: 600;
  color: #fff;
  font-family: var(--font-mono);
}

.badge-status {
  font-size: 0.78rem;
  color: var(--accent-emerald);
  background: rgba(16, 185, 129, 0.12);
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.direct-email-cta {
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid var(--border-highlight);
  border-radius: var(--radius-md);
  padding: 36px 30px;
  text-align: center;
  box-shadow: 0 0 30px rgba(6, 182, 212, 0.08);
}

.direct-email-cta h3 {
  font-size: 1.4rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 12px;
}

.direct-email-cta p {
  color: var(--text-muted);
  font-size: 0.94rem;
  margin-bottom: 24px;
  line-height: 1.6;
}

/* --------------------------------------------------------------------------
   15. Site Footer
   -------------------------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 30px 0;
  background: var(--bg-dark);
  font-size: 0.88rem;
  color: var(--text-dim);
  position: relative;
  z-index: 10;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-right a:hover {
  color: var(--accent-cyan);
}

/* --------------------------------------------------------------------------
   16. Modern <dialog> Deep Dive Modal
   -------------------------------------------------------------------------- */
.deep-dive-dialog {
  border: none;
  border-radius: var(--radius-lg);
  background: transparent;
  padding: 0;
  margin: auto;
  max-width: 900px;
  width: 92vw;
  max-height: 90vh;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.85);
  color: var(--text-main);
  overflow: hidden;

  /* Entry transition */
  opacity: 0;
  transform: scale(0.96) translateY(10px);
  transition: opacity 0.25s ease-out, transform 0.25s ease-out, display 0.25s allow-discrete, overlay 0.25s allow-discrete;
}

.deep-dive-dialog[open] {
  opacity: 1;
  transform: scale(1) translateY(0);

  @starting-style {
    opacity: 0;
    transform: scale(0.96) translateY(10px);
  }
}

.deep-dive-dialog::backdrop {
  background-color: rgba(3, 7, 18, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  opacity: 0;
  transition: opacity 0.25s ease-out, display 0.25s allow-discrete, overlay 0.25s allow-discrete;
}

.deep-dive-dialog[open]::backdrop {
  opacity: 1;

  @starting-style {
    opacity: 0;
  }
}

.dialog-card {
  background: rgba(15, 23, 42, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  max-height: 90vh;
  overflow: hidden;
}

.dialog-header {
  padding: 24px 28px;
  border-bottom: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(20, 29, 51, 0.9);
}

.dialog-badge {
  font-size: 0.74rem;
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--accent-cyan);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 4px;
  display: block;
}

.dialog-title {
  font-size: 1.45rem;
  font-weight: 800;
  color: #fff;
}

.dialog-close-btn {
  font-size: 2rem;
  color: var(--text-muted);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all var(--transition-fast);
}

.dialog-close-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.dialog-body {
  padding: 28px;
  overflow-y: auto;
  line-height: 1.7;
}

/* Modal Internal Sections */
.modal-section {
  margin-bottom: 28px;
}

.modal-section h4 {
  font-size: 1.15rem;
  color: #fff;
  font-weight: 700;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-section h4::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 16px;
  background: var(--accent-cyan);
  border-radius: 2px;
}

.modal-tech-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
}

.matrix-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
  margin-top: 10px;
}

.matrix-table th, .matrix-table td {
  padding: 12px 14px;
  text-align: left;
  border-bottom: 1px solid var(--border-subtle);
}

.matrix-table th {
  background: rgba(255, 255, 255, 0.03);
  color: var(--accent-cyan);
  font-weight: 700;
  font-family: var(--font-mono);
}

.matrix-table td {
  color: var(--text-muted);
}

.matrix-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
  color: #fff;
}

/* --------------------------------------------------------------------------
   16b. Modern High-Resolution Image Lightbox Modal (<dialog>)
   -------------------------------------------------------------------------- */
.lightbox-dialog {
  border: none;
  background: transparent;
  padding: 0;
  margin: auto;
  max-width: 1040px;
  width: 95vw;
  max-height: 94vh;
  box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.95);
  color: var(--text-main);
  overflow: hidden;
  opacity: 0;
  transform: scale(0.96);
  transition: opacity 0.22s ease-out, transform 0.22s ease-out, display 0.22s allow-discrete, overlay 0.22s allow-discrete;
}

.lightbox-dialog[open] {
  opacity: 1;
  transform: scale(1);

  @starting-style {
    opacity: 0;
    transform: scale(0.96);
  }
}

.lightbox-dialog::backdrop {
  background-color: rgba(3, 7, 18, 0.88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  opacity: 0;
  transition: opacity 0.22s ease-out, display 0.22s allow-discrete, overlay 0.22s allow-discrete;
}

.lightbox-dialog[open]::backdrop {
  opacity: 1;

  @starting-style {
    opacity: 0;
  }
}

.lightbox-dialog-card {
  background: rgba(13, 20, 36, 0.98);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  max-height: 94vh;
  overflow: hidden;
}

.lightbox-header {
  padding: 16px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(18, 26, 46, 0.95);
  border-bottom: 1px solid var(--border-subtle);
}

.lightbox-header-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.lightbox-role-badge {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  font-family: var(--font-mono);
  color: var(--accent-cyan);
  letter-spacing: 0.06em;
}

.lightbox-title {
  font-size: 1.25rem;
  font-weight: 750;
  color: #fff;
}

.lightbox-header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.lightbox-counter-pill {
  font-size: 0.8rem;
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.06);
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.lightbox-close-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  font-size: 1.6rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  line-height: 1;
  transition: all var(--transition-fast);
}

.lightbox-close-btn:hover {
  background: rgba(239, 68, 68, 0.2);
  border-color: #ef4444;
  color: #ef4444;
  transform: scale(1.05);
}

.lightbox-stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px 20px;
  background: rgba(2, 6, 18, 0.85);
  min-height: 340px;
  max-height: 64vh;
  overflow: hidden;
}

.lightbox-img-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  max-height: 60vh;
}

.lightbox-main-img {
  max-height: 60vh;
  max-width: 100%;
  object-fit: contain;
  border-radius: var(--radius-sm);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.8);
  transition: opacity 0.2s ease;
}

.lightbox-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
  z-index: 10;
}

.lightbox-nav-btn:hover {
  background: var(--accent-cyan);
  color: #030712;
  border-color: var(--accent-cyan);
  transform: translateY(-50%) scale(1.08);
  box-shadow: 0 0 20px rgba(6, 182, 212, 0.55);
}

.lightbox-nav-btn.prev {
  left: 20px;
}

.lightbox-nav-btn.next {
  right: 20px;
}

.lightbox-footer {
  padding: 16px 24px;
  background: rgba(18, 26, 46, 0.95);
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.lightbox-desc-box {
  flex: 1;
}

.lightbox-description {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
  max-width: 700px;
}

.lightbox-footer-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

.lightbox-nav-hint {
  font-size: 0.76rem;
  color: var(--text-dim);
}

.lightbox-nav-hint kbd {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 3px;
  padding: 2px 6px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: #fff;
}

.lightbox-raw-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent-cyan);
  border: 1px solid rgba(6, 182, 212, 0.3);
  padding: 6px 14px;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}

.lightbox-raw-link:hover {
  background: rgba(6, 182, 212, 0.15);
  border-color: var(--accent-cyan);
  color: #fff;
}

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

.toast {
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid var(--accent-emerald);
  color: #fff;
  padding: 12px 20px;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
  font-size: 0.88rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 10px;
  animation: slideInToast 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

/* --------------------------------------------------------------------------
   18. Responsive Media Queries
   -------------------------------------------------------------------------- */
@media (max-width: 1024px) {
  .hero-container {
    grid-template-columns: 1fr;
    gap: 40px;
  }

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

  .project-header {
    padding-right: 0;
  }

  .project-ribbon {
    position: static;
    display: inline-block;
    margin-bottom: 12px;
  }

  .arch-layer-breakdown {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact-box {
    grid-template-columns: 1fr;
  }

  .gallery-cards-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }

  .gallery-card.landscape-card {
    grid-column: span 2;
  }

  .gallery-card.portrait-card {
    grid-column: span 1;
  }
}

@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: rgba(7, 10, 18, 0.98);
    flex-direction: column;
    padding: 24px;
    gap: 18px;
    border-bottom: 1px solid var(--border-subtle);
    display: none;
  }

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

  .mobile-toggle {
    display: flex;
  }

  .gallery-cards-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .gallery-card.landscape-card {
    grid-column: span 2;
  }

  .gallery-card.portrait-card {
    grid-column: span 1;
  }

  .gallery-header-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .lightbox-header {
    padding: 12px 16px;
  }

  .lightbox-title {
    font-size: 1.05rem;
  }

  .lightbox-stage {
    min-height: 260px;
    padding: 12px 8px;
  }

  .lightbox-nav-btn {
    width: 38px;
    height: 38px;
  }

  .lightbox-nav-btn.prev {
    left: 8px;
  }

  .lightbox-nav-btn.next {
    right: 8px;
  }

  .lightbox-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 16px;
  }

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

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

  .project-highlights-grid {
    grid-template-columns: 1fr;
  }

  .arch-layer-breakdown {
    grid-template-columns: 1fr;
  }

  .reference-card {
    flex-direction: column;
    align-items: flex-start;
  }
}

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

  .gallery-cards-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .gallery-card.landscape-card,
  .gallery-card.portrait-card {
    grid-column: span 1;
  }

  .gallery-card.portrait-card .gallery-card-thumb {
    aspect-ratio: 9 / 15;
  }

  .gallery-card.landscape-card .gallery-card-thumb {
    aspect-ratio: 16 / 10;
  }

  .btn-expand-gallery {
    width: 100%;
    justify-content: center;
    font-size: 0.85rem;
    padding: 10px 16px;
  }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
