:root {
  /* ---- Pixel-black palette ---- */
  --bg-primary: #000000;
  --bg-secondary: #050506;
  --bg-card: #070709;
  --bg-card-hover: #0d0d11;
  --bg-inset: #030304;

  --border-color: #23232b;
  --border-strong: #35353f;
  --border-accent: rgba(56, 189, 248, 0.55);

  --text-main: #f4f4f5;
  --text-muted: #9a9aa3;
  --text-dim: #6b6b75;

  --accent-cyan: #22d3ee;
  --accent-cyan-glow: rgba(34, 211, 238, 0.25);
  --accent-violet: #a78bfa;
  --accent-violet-glow: rgba(167, 139, 250, 0.25);
  --accent-emerald: #34d399;
  --accent-emerald-glow: rgba(52, 211, 153, 0.25);
  --accent-amber: #fbbf24;

  --gradient-brand: linear-gradient(135deg, #22d3ee 0%, #3b82f6 50%, #a78bfa 100%);
  --gradient-glow: radial-gradient(circle at 50% 0%, rgba(59, 130, 246, 0.12), transparent 75%);

  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --font-heading: 'Space Grotesk', var(--font-sans);

  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-smooth: 0.35s cubic-bezier(0.16, 1, 0.3, 1);

  /* Pixel geometry — crisp square corners everywhere */
  --radius-sm: 2px;
  --radius-md: 2px;
  --radius-lg: 2px;
  --radius-full: 2px;

  /* Pixel texture + blocky shadows */
  --pixel-grid: rgba(255, 255, 255, 0.05);
  --pixel-grid-major: rgba(255, 255, 255, 0.075);
  --pixel-checker: rgba(255, 255, 255, 0.05);
  --shadow-card: inset 1px 1px 0 rgba(255, 255, 255, 0.055), inset -1px -1px 0 rgba(0, 0, 0, 0.9);
  --shadow-glow: 0 0 0 1px rgba(34, 211, 238, 0.45);
}


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

html {
  scroll-behavior: smooth;
  /* Keeps anchored sections clear of the fixed navbar */
  scroll-padding-top: 110px;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

img {
  max-width: 100%;
}

body {
  background-color: var(--bg-primary);
  background-image:
    linear-gradient(to right, var(--pixel-grid) 1px, transparent 1px),
    linear-gradient(to bottom, var(--pixel-grid) 1px, transparent 1px);
  background-size: 16px 16px;
  background-attachment: fixed;
  color: var(--text-main);
  font-family: var(--font-sans);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
  transition: background-color var(--transition-smooth), color var(--transition-smooth);
}

/* Pixel-art text selection */
::selection {
  background: var(--accent-cyan);
  color: #000000;
}

/* Chunky pixel scrollbar */
::-webkit-scrollbar {
  width: 14px;
  height: 14px;
}
::-webkit-scrollbar-track {
  background: #000000;
  border-left: 1px solid var(--border-color);
}
::-webkit-scrollbar-thumb {
  background: #2a2a34;
  border: 3px solid #000000;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent-cyan);
}

/* Background Atmosphere — pixel / CRT layers */
.ambient-background {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  overflow: hidden;
}

/* Dithered 8-bit checkerboard haze */
.ambient-background::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: repeating-conic-gradient(var(--pixel-checker) 0% 25%, transparent 0% 50%);
  background-size: 8px 8px;
  opacity: 0.5;
}

/* CRT scanlines */
.ambient-background::after {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.035) 0px,
    rgba(255, 255, 255, 0.035) 1px,
    transparent 1px,
    transparent 4px
  );
  opacity: 0.6;
}

/* Orbs become dithered pixel glows: hard concentric steps, zero blur */
.ambient-orb {
  position: absolute;
  border-radius: 0;
  filter: none;
  opacity: 1;
  image-rendering: pixelated;
  will-change: transform;
  -webkit-mask-image: repeating-conic-gradient(#000 0 25%, transparent 0 50%);
  mask-image: repeating-conic-gradient(#000 0 25%, transparent 0 50%);
  -webkit-mask-size: 8px 8px;
  mask-size: 8px 8px;
}

.orb-1 {
  width: 520px;
  height: 520px;
  top: -120px;
  left: 6%;
  background-image: radial-gradient(circle at center,
      rgba(34, 211, 238, 0.50) 0 16%,
      rgba(34, 211, 238, 0.28) 16% 30%,
      rgba(34, 211, 238, 0.13) 30% 44%,
      rgba(34, 211, 238, 0.05) 44% 58%,
      transparent 58%);
  animation: floatOrb 24s ease-in-out infinite alternate;
}

.orb-2 {
  width: 460px;
  height: 460px;
  top: 28%;
  right: -60px;
  background-image: radial-gradient(circle at center,
      rgba(167, 139, 250, 0.45) 0 16%,
      rgba(167, 139, 250, 0.24) 16% 30%,
      rgba(167, 139, 250, 0.11) 30% 44%,
      rgba(167, 139, 250, 0.04) 44% 58%,
      transparent 58%);
  animation: floatOrb 30s ease-in-out infinite alternate-reverse;
}

.orb-3 {
  width: 620px;
  height: 620px;
  bottom: 8%;
  left: 18%;
  background-image: radial-gradient(circle at center,
      rgba(59, 130, 246, 0.45) 0 16%,
      rgba(59, 130, 246, 0.22) 16% 30%,
      rgba(59, 130, 246, 0.10) 30% 44%,
      rgba(59, 130, 246, 0.04) 44% 58%,
      transparent 58%);
  animation: floatOrb 36s ease-in-out infinite alternate;
}

/* Major 96px grid on top of the 16px base grid */
.grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, var(--pixel-grid-major) 1px, transparent 1px),
    linear-gradient(to bottom, var(--pixel-grid-major) 1px, transparent 1px);
  background-size: 96px 96px;
  mask-image: radial-gradient(ellipse at 50% 25%, rgba(0, 0, 0, 0.9) 0%, transparent 82%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 25%, rgba(0, 0, 0, 0.9) 0%, transparent 82%);
}

/* Cursor-driven pixel warp lens (painted by js/app.js) */
.pixel-warp-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.pixel-warp-canvas.is-active {
  opacity: 1;
}

/* Silky orb drift (GPU-composited, no stepping) */
@keyframes floatOrb {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(56px, 40px, 0) scale(1.08); }
  100% { transform: translate3d(-40px, 64px, 0) scale(0.94); }
}

/* Layout Utilities */
.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

section {
  padding: 6rem 0;
  position: relative;
}

/* Typography & Headings */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  line-height: 1.15;
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.02em;
}

.gradient-text {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

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

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.9rem;
  border-radius: 0;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  background: #050506;
  color: var(--accent-cyan);
  border: 1px solid rgba(34, 211, 238, 0.35);
  box-shadow: 3px 3px 0 rgba(34, 211, 238, 0.14);
  margin-bottom: 1.25rem;
}

.badge-pulse {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 0;
  background-color: var(--accent-emerald);
  box-shadow: 0 0 10px var(--accent-emerald);
  animation: pulse 2.6s ease-in-out infinite;
}

@keyframes pulse {
  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 8px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

.section-header h2 {
  font-size: clamp(2rem, 3.5vw, 2.75rem);
  margin-bottom: 1rem;
}

.section-header p {
  color: var(--text-muted);
  font-size: 1.1rem;
  line-height: 1.6;
}

/* Pixel card surface (flat black, beveled edge, square corners) */
.glass-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 0;
  padding: 2rem;
  box-shadow: inset 1px 1px 0 rgba(255, 255, 255, 0.055), inset -1px -1px 0 rgba(0, 0, 0, 0.9);
  transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.glass-card:hover {
  transform: translate(-2px, -2px);
  border-color: var(--accent-cyan);
  box-shadow: 4px 4px 0 rgba(34, 211, 238, 0.28), inset 1px 1px 0 rgba(255, 255, 255, 0.08);
}

/* Header & Navigation — transparent pixel bar (frosted only after scroll) */
.navbar {
  position: fixed;
  top: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  width: 90%;
  max-width: 1200px;
  z-index: 1000;
  background: transparent;
  border: 1px solid transparent;
  border-radius: 0;
  padding: 0.75rem 1.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: none;
  transition: background-color 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
}

/* Once the page scrolls, keep links readable with a translucent black slab */
.navbar.is-scrolled {
  background: rgba(0, 0, 0, 0.68);
  border-color: var(--border-color);
  box-shadow: inset 1px 1px 0 rgba(255, 255, 255, 0.06), 4px 4px 0 rgba(0, 0, 0, 0.65);
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  flex-shrink: 0;
  color: var(--text-main);
  transition: color var(--transition-fast);
}

.nav-brand:hover {
  color: var(--accent-cyan);
}

.brand-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--gradient-brand);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  font-weight: 700;
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.4);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  list-style: none;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 500;
  transition: color var(--transition-fast);
  position: relative;
}

.nav-links a:hover, .nav-links a.active {
  color: var(--accent-cyan);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gradient-brand);
  transition: width var(--transition-fast);
  border-radius: 2px;
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.nav-actions .btn {
  white-space: nowrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.4rem;
  border-radius: 0;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all var(--transition-fast);
}

.btn-primary {
  background: var(--gradient-brand);
  color: #ffffff;
  box-shadow: 4px 4px 0 rgba(34, 211, 238, 0.28);
}

.btn-primary:hover {
  transform: translate(-2px, -2px);
  box-shadow: 7px 7px 0 rgba(34, 211, 238, 0.42);
}

.btn-outline {
  background: #050506;
  color: var(--text-main);
  border: 1px solid var(--border-color);
  box-shadow: 3px 3px 0 rgba(255, 255, 255, 0.06);
}

.btn-outline:hover {
  background: #0b0b0f;
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 rgba(34, 211, 238, 0.24);
}

/* Custom pure-black button (Footer "Top" / back-to-top) */
.btn-black {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: linear-gradient(180deg, #151517 0%, #050505 55%, #000000 100%);
  color: #ffffff;
  font-weight: 600;
  letter-spacing: 0.04em;
  border: 1px solid #33333d;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    inset 0 -1px 0 rgba(0, 0, 0, 0.9),
    3px 3px 0 rgba(255, 255, 255, 0.12);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Diagonal light sweep that glides across the surface on hover */
.btn-black::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    115deg,
    transparent 25%,
    rgba(255, 255, 255, 0.22) 48%,
    rgba(255, 255, 255, 0.06) 58%,
    transparent 75%
  );
  transform: translateX(-130%);
  transition: transform 0.65s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-black:hover {
  color: #ffffff;
  border-color: #6b6b78;
  transform: translate(-2px, -2px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    inset 0 -1px 0 rgba(0, 0, 0, 0.9),
    6px 6px 0 rgba(255, 255, 255, 0.18);
}

.btn-black:hover::before {
  transform: translateX(130%);
}

.btn-black:active {
  transform: translate(1px, 1px);
  box-shadow:
    inset 0 2px 6px rgba(0, 0, 0, 0.9),
    1px 1px 0 rgba(255, 255, 255, 0.1);
}

.btn-black:focus-visible {
  outline: 2px solid var(--accent-cyan);
  outline-offset: 3px;
}

.btn-black .fa-arrow-up {
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-black:hover .fa-arrow-up {
  transform: translateY(-3px);
}

.theme-toggle-btn {
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

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

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

/* Hero Section */
.hero-section {
  padding-top: 11rem;
  padding-bottom: 6rem;
  min-height: 90vh;
  display: flex;
  align-items: center;
}

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

.hero-content h1 {
  font-size: clamp(2.5rem, 4.5vw, 3.85rem);
  line-height: 1.08;
  margin-bottom: 1.5rem;
  font-weight: 800;
}

.hero-content p.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  line-height: 1.65;
  margin-bottom: 2rem;
  max-width: 580px;
}

.hero-stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 2.75rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}

.stat-item .stat-value {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 0.25rem;
}

.stat-item p {
  font-size: 0.85rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

/* Terminal / Interactive Hero Window */
.terminal-window {
  background: #0d121f;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.8), 0 0 35px rgba(6, 182, 212, 0.15);
}

.terminal-header {
  background: #151c2d;
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

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

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

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

.terminal-title {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.terminal-body {
  padding: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.88rem;
  color: #e2e8f0;
  line-height: 1.7;
  min-height: 330px;
}

.code-prompt {
  color: var(--accent-emerald);
}

.code-keyword {
  color: var(--accent-cyan);
}

.code-string {
  color: #fbcfe8;
}

.code-func {
  color: #60a5fa;
}

.terminal-cursor {
  display: inline-block;
  width: 8px;
  height: 15px;
  background-color: var(--accent-cyan);
  vertical-align: middle;
  animation: blink 1s step-start infinite;
}

@keyframes blink {
  50% { opacity: 0; }
}

.quick-tech-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.tech-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.6rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Skills & Tech Stack Grid */
.skills-filter-bar {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

.filter-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  padding: 0.5rem 1.25rem;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-btn:hover, .filter-btn.active {
  background: var(--accent-cyan);
  border-color: var(--accent-cyan);
  color: #0b0f19;
  box-shadow: 0 0 15px rgba(6, 182, 212, 0.4);
}

.tech-domains-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(350px, 100%), 1fr));
  gap: 1.75rem;
}

.domain-card {
  border-top: 3px solid transparent;
  transition: all var(--transition-smooth);
}

.domain-card.web { border-top-color: var(--accent-cyan); }
.domain-card.mobile { border-top-color: #10b981; }
.domain-card.database { border-top-color: #3b82f6; }
.domain-card.cloud { border-top-color: #8b5cf6; }
.domain-card.devops { border-top-color: #f59e0b; }

.domain-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.domain-icon-box {
  width: 46px;
  height: 46px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--accent-cyan);
}

.domain-title {
  font-size: 1.25rem;
}

.domain-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  line-height: 1.55;
}

.domain-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.domain-tag-item {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.75rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-main);
  transition: all var(--transition-fast);
}

.domain-tag-item:hover {
  border-color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.08);
  transform: translateY(-2px);
}

/* Service Delivery Process (How I Deliver) */
.delivery-section {
  position: relative;
}

.delivery-timeline {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  position: relative;
  margin-top: 3rem;
}

.delivery-step-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2.25rem 1.5rem;
  position: relative;
  display: flex;
  flex-direction: column;
  transition: all var(--transition-smooth);
}

.step-num-badge {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.3);
  color: var(--accent-cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
}

.delivery-step-card:hover {
  transform: translateY(-6px);
  border-color: var(--accent-cyan);
  box-shadow: 0 15px 35px -10px rgba(6, 182, 212, 0.2);
}

.step-title {
  font-size: 1.2rem;
  margin-bottom: 0.75rem;
}

.step-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 1.25rem;
}

.step-deliverables {
  margin-top: auto;
  border-top: 1px solid var(--border-color);
  padding-top: 1rem;
  list-style: none;
}

.step-deliverables li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-bottom: 0.35rem;
}

.step-deliverables li i {
  color: var(--accent-emerald);
  font-size: 0.75rem;
}

/* Featured Portfolio Showcase */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(360px, 100%), 1fr));
  gap: 2rem;
}

.project-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all var(--transition-smooth);
}

.project-card:hover {
  transform: translateY(-6px);
  border-color: var(--accent-cyan);
  box-shadow: 0 20px 45px -15px rgba(0, 0, 0, 0.7), 0 0 25px rgba(6, 182, 212, 0.15);
}

.project-preview {
  height: 230px;
  background: #111827;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border-color);
}

.project-preview-gallery {
  width: 100%;
  height: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #090d16;
}

.project-img-wrapper {
  width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.project-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-smooth);
}

.project-card:hover .project-img-wrapper img {
  transform: scale(1.05);
}

.project-pics-placeholder {
  width: 90%;
  height: 85%;
  border: 2px dashed rgba(6, 182, 212, 0.4);
  background: rgba(15, 23, 42, 0.8);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1.25rem;
  transition: all var(--transition-smooth);
  cursor: pointer;
}

.project-card:hover .project-pics-placeholder {
  border-color: var(--accent-cyan);
  background: rgba(15, 23, 42, 0.95);
  box-shadow: 0 0 25px rgba(6, 182, 212, 0.15);
}

.pics-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.65rem;
  background: rgba(6, 182, 212, 0.15);
  border: 1px solid rgba(6, 182, 212, 0.3);
  color: var(--accent-cyan);
  font-size: 0.72rem;
  border-radius: var(--radius-full);
  margin-top: 0.5rem;
  font-weight: 600;
}

.project-mockup-canvas {
  width: 90%;
  height: 85%;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  padding: 1rem;
  position: relative;
  background-size: cover;
  background-position: center;
  transition: transform var(--transition-smooth);
}

.project-card:hover .project-mockup-canvas {
  transform: scale(1.03);
}

.mockup-app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding-bottom: 0.5rem;
  margin-bottom: 0.75rem;
}

.mockup-category {
  position: absolute;
  top: 1rem;
  left: 1rem;
  padding: 0.3rem 0.7rem;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent-cyan);
  border: 1px solid rgba(255, 255, 255, 0.1);
  z-index: 2;
}

.project-content {
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.project-content h3 {
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
}

.project-content p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  flex: 1;
}

.project-tech-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.project-links {
  display: flex;
  gap: 0.75rem;
  margin-top: auto;
}

/* Interactive Project Scope & Timeline Estimator */
.estimator-box {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  margin-top: 4rem;
}

.estimator-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2.5rem;
  align-items: center;
}

.estimator-options {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.option-group label {
  display: block;
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 0.65rem;
  color: var(--text-main);
}

.select-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.scope-pill {
  padding: 0.55rem 1rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  font-size: 0.85rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  color: var(--text-muted);
  user-select: none;
}

.scope-pill.active {
  background: rgba(6, 182, 212, 0.15);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
  font-weight: 600;
}

.estimator-result-card {
  background: #0d1322;
  border: 1px solid rgba(6, 182, 212, 0.3);
  border-radius: var(--radius-md);
  padding: 2rem;
  text-align: center;
}

.result-time-value {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--accent-cyan);
  font-family: var(--font-heading);
}

.result-tagline {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 1.5rem;
}

/* Contact & Booking Section */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 3.5rem;
}

.contact-info-card {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.contact-perk {
  display: flex;
  gap: 1.25rem;
}

.perk-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-cyan);
  font-size: 1.25rem;
  flex-shrink: 0;
}

.perk-text h3 {
  font-size: 1.1rem;
  margin-bottom: 0.25rem;
}

.perk-text p {
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

.contact-form-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
}

.form-group {
  margin-bottom: 1.35rem;
}

.form-group label {
  display: block;
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text-main);
}

.form-control {
  width: 100%;
  padding: 0.85rem 1.1rem;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  color: var(--text-main);
  font-family: var(--font-sans);
  font-size: 0.92rem;
  transition: all var(--transition-fast);
}

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

textarea.form-control {
  min-height: 120px;
  resize: vertical;
}

/* Modals */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-smooth);
}

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

.modal-box {
  background: #0f172a;
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-lg);
  width: 90%;
  max-width: 550px;
  padding: 2.5rem;
  text-align: center;
  position: relative;
  transform: translateY(20px) scale(0.95);
  transition: transform var(--transition-smooth);
  box-shadow: 0 25px 60px rgba(0,0,0,0.8);
}

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

.modal-close-btn {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  background: none;
  border: none;
  color: var(--text-dim);
  font-size: 1.25rem;
  cursor: pointer;
}

.modal-close-btn:hover {
  color: var(--text-main);
}

/* Toast notification */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  background: #10b981;
  color: #ffffff;
  padding: 0.85rem 1.4rem;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  box-shadow: 0 10px 25px rgba(16, 185, 129, 0.4);
  transform: translateY(100px);
  opacity: 0;
  transition: all var(--transition-smooth);
  z-index: 3000;
}

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

/* Footer */
footer {
  border-top: 1px solid var(--border-color);
  padding: 4rem 0 2rem 0;
  background: rgba(10, 15, 26, 0.7);
}

.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-dim);
  font-size: 0.85rem;
  border-top: 1px solid var(--border-color);
  padding-top: 2rem;
}

/* =========================================================
   PIXEL THEME — COMPONENT LAYER
   Flat black surfaces, square corners, blocky hardware shadows
   ========================================================= */

/* All panels become opaque black slabs */
.glass-card,
.project-card,
.delivery-step-card,
.estimator-box,
.estimator-result-card,
.contact-form-card,
.terminal-window,
.modal-box {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 0;
  box-shadow: inset 1px 1px 0 rgba(255, 255, 255, 0.05), inset -1px -1px 0 rgba(0, 0, 0, 0.9);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

/* Stepped pixel-notch corners (page-black bites) */
.glass-card::before,
.project-card::before,
.delivery-step-card::before,
.estimator-box::before,
.estimator-result-card::before,
.contact-form-card::before,
.terminal-window::before,
.modal-box::before {
  content: "";
  position: absolute;
  inset: -1px;
  z-index: 3;
  pointer-events: none;
  background:
    linear-gradient(var(--bg-primary), var(--bg-primary)) top left / 6px 6px no-repeat,
    linear-gradient(var(--bg-primary), var(--bg-primary)) top right / 6px 6px no-repeat,
    linear-gradient(var(--bg-primary), var(--bg-primary)) bottom left / 6px 6px no-repeat,
    linear-gradient(var(--bg-primary), var(--bg-primary)) bottom right / 6px 6px no-repeat;
}

.project-card:hover,
.delivery-step-card:hover {
  transform: translate(-2px, -2px);
  border-color: var(--accent-cyan);
  box-shadow: 4px 4px 0 rgba(34, 211, 238, 0.22), inset 1px 1px 0 rgba(255, 255, 255, 0.08);
}

/* Keep the 3px category stripe on skill cards */
.domain-card {
  border-top-width: 3px;
  border-top-style: solid;
}

/* Hero terminal */
.terminal-window {
  background: #040405;
  border-color: #2a2a34;
  box-shadow: 6px 6px 0 #0b0b0e, inset 1px 1px 0 rgba(255, 255, 255, 0.06);
}

.terminal-header {
  background: #0a0a0d;
  border-bottom: 1px solid #26262f;
}

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

.terminal-body {
  color: #d8d8de;
}

/* Estimator */
.estimator-box {
  background: #030304;
  border-color: #2a2a34;
}

.estimator-result-card {
  background: #050506;
  border: 1px solid rgba(34, 211, 238, 0.35);
  box-shadow: 4px 4px 0 rgba(34, 211, 238, 0.14), inset 1px 1px 0 rgba(255, 255, 255, 0.04);
}

/* Chips, pills & tags */
.tech-tag,
.domain-tag-item,
.scope-pill,
.pics-badge,
.mockup-category {
  background: #050506;
  border-radius: 0;
}

.tech-tag,
.domain-tag-item {
  border-color: #26262f;
}

.domain-tag-item:hover {
  transform: translate(-1px, -1px);
  box-shadow: 2px 2px 0 rgba(34, 211, 238, 0.2);
}

.scope-pill {
  box-shadow: 3px 3px 0 rgba(255, 255, 255, 0.05);
  border-color: #26262f;
}

.scope-pill.active {
  background: rgba(34, 211, 238, 0.12);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
  box-shadow: 3px 3px 0 rgba(34, 211, 238, 0.22);
}

.filter-btn {
  background: #050506;
  border: 1px solid var(--border-color);
  border-radius: 0;
  box-shadow: 3px 3px 0 rgba(255, 255, 255, 0.05);
}

.filter-btn:hover,
.filter-btn.active {
  background: var(--accent-cyan);
  border-color: var(--accent-cyan);
  color: #000000;
  box-shadow: 4px 4px 0 rgba(34, 211, 238, 0.3);
}

/* Icon tiles */
.domain-icon-box,
.perk-icon,
.step-num-badge {
  border-radius: 0;
  background: #050506;
}

.domain-icon-box {
  border: 1px solid #26262f;
  box-shadow: 2px 2px 0 #0b0b0e;
}

.perk-icon {
  border: 1px solid rgba(34, 211, 238, 0.35);
  box-shadow: 2px 2px 0 rgba(34, 211, 238, 0.12);
}

.step-num-badge {
  border: 1px solid rgba(34, 211, 238, 0.4);
  box-shadow: 2px 2px 0 rgba(34, 211, 238, 0.15);
}

.brand-icon {
  border-radius: 0;
}

.nav-links a::after {
  border-radius: 0;
  height: 3px;
}

/* Project showcase surfaces */
.project-preview,
.project-preview-gallery {
  background: #030304;
}

.project-pics-placeholder {
  background: #050506;
  border: 2px dashed #2a2a34;
  border-radius: 0;
}

.project-card:hover .project-pics-placeholder {
  background: #0a0a0d;
  border-color: var(--accent-cyan);
  box-shadow: none;
}

.project-mockup-canvas {
  border-radius: 0;
}

.mockup-category,
.pics-badge {
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-radius: 0;
}

/* Forms */
.form-control {
  background: #030304;
  border: 1px solid var(--border-color);
  border-radius: 0;
  color: var(--text-main);
  box-shadow: inset 2px 2px 0 rgba(0, 0, 0, 0.8);
}

.form-control:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 2px rgba(34, 211, 238, 0.28), inset 2px 2px 0 rgba(0, 0, 0, 0.8);
}

/* Modal */
.modal-overlay {
  background: rgba(0, 0, 0, 0.88);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.modal-box {
  background: #050506;
  border: 1px solid rgba(34, 211, 238, 0.4);
  box-shadow: 8px 8px 0 #0c0c10, inset 1px 1px 0 rgba(255, 255, 255, 0.05);
}

/* Toast */
.toast {
  background: #050506;
  color: var(--text-main);
  border: 1px solid var(--accent-emerald);
  border-left-width: 4px;
  border-radius: 0;
  box-shadow: 4px 4px 0 rgba(52, 211, 153, 0.25);
}

.toast i {
  color: var(--accent-emerald);
}

/* Footer slab */
footer {
  background: rgba(0, 0, 0, 0.72);
  border-top: 1px solid var(--border-color);
}

/* Respect reduced-motion preferences */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .ambient-orb,
  .badge-pulse,
  .terminal-cursor {
    animation: none !important;
  }
}

/* Project screenshot selector chips */
.project-thumb-grid .btn {
  min-height: 36px;
  padding: 0.45rem 0.6rem;
  font-size: 0.75rem;
}

.project-thumb-grid.is-three .btn {
  padding: 0.45rem 0.4rem;
  font-size: 0.72rem;
  text-align: center;
}

/* Responsive Rules */
@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  .delivery-timeline {
    grid-template-columns: repeat(2, 1fr);
  }
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  .estimator-grid {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }
}

@media (max-width: 1180px) {
  /* Nav switches to the collapsible menu before the desktop row can crowd */
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 0.6rem;
    background: #050506;
    border: 1px solid var(--border-color);
    border-radius: 0;
    flex-direction: column;
    padding: 0.6rem;
    gap: 0.15rem;
    box-shadow: 6px 6px 0 #000000;
  }
  .nav-links.active {
    display: flex;
  }
  .nav-links li {
    width: 100%;
  }
  .nav-links a {
    display: block;
    padding: 0.85rem 0.9rem;
    font-size: 1rem;
  }
  .nav-links a::after {
    display: none;
  }
  .mobile-menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    font-size: 1.25rem;
    position: relative;
  }
  /* Slightly larger hit area than the visible icon box */
  .mobile-menu-toggle::after {
    content: "";
    position: absolute;
    inset: -4px;
  }
}

@media (min-width: 769px) and (max-width: 1180px) {
  /* Tablet/compact-laptop dropdown: a right-aligned panel instead of a full-width bar */
  .nav-links {
    left: auto;
    right: 0;
    min-width: 280px;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 1.15rem;
  }
  section {
    padding: 3.5rem 0;
  }
  .hero-section {
    padding-top: 7.5rem;
    padding-bottom: 4rem;
    min-height: 0;
  }
  .section-header {
    margin-bottom: 2.5rem;
  }
  html {
    scroll-padding-top: 96px;
  }

  /* --- Navigation --- */
  .navbar {
    width: calc(100% - 1.5rem);
    top: 0.7rem;
    padding: 0.55rem 0.8rem;
    gap: 0.5rem;
  }
  .nav-brand {
    font-size: 0.92rem;
    letter-spacing: 0.03em;
  }
  .nav-actions {
    gap: 0.4rem;
  }
  .nav-actions .btn {
    padding: 0.55rem 0.85rem;
    font-size: 0.78rem;
  }
  .mobile-menu-toggle {
    width: 34px;
    height: 34px;
  }

  /* --- Content blocks --- */
  .glass-card {
    padding: 1.4rem;
  }
  .domain-icon-box {
    width: 42px;
    height: 42px;
    font-size: 1.15rem;
  }
  .delivery-step-card {
    padding: 1.6rem 1.2rem;
  }
  .delivery-timeline {
    grid-template-columns: 1fr;
  }
  .project-preview {
    height: 200px;
  }
  .project-content {
    padding: 1.25rem;
  }
  .project-links {
    flex-wrap: wrap;
  }
  .filter-btn {
    padding: 0.6rem 1.05rem;
  }
  .project-thumb-grid .btn,
  .project-thumb-grid.is-three .btn {
    min-height: 42px;
    padding: 0.55rem 0.5rem;
    font-size: 0.74rem;
  }
  .estimator-box {
    padding: 1.4rem;
  }
  .estimator-result-card {
    padding: 1.25rem;
  }
  .result-time-value {
    font-size: 2rem;
  }
  .contact-form-card {
    padding: 1.4rem;
  }
  .modal-box {
    width: calc(100% - 2rem);
    padding: 1.75rem;
  }
  .terminal-body {
    font-size: 0.78rem;
    padding: 1.1rem;
    min-height: 270px;
    overflow-wrap: anywhere;
  }
  .terminal-header {
    padding: 0.65rem 0.8rem;
  }

  /* 16px inputs stop iOS from zooming the page on focus */
  .form-control {
    font-size: 16px;
  }

  .hero-stats-row {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }
  .stat-item .stat-value {
    font-size: 1.75rem;
  }

  .footer-bottom {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.6rem;
  }
  .toast {
    left: 1.15rem;
    right: 1.15rem;
    bottom: 1.15rem;
  }
}

@media (max-width: 480px) {
  html {
    scroll-padding-top: 88px;
  }
  section {
    padding: 3rem 0;
  }
  .hero-section {
    padding-top: 7rem;
  }
  .hero-content h1 {
    font-size: clamp(1.95rem, 9.5vw, 2.45rem);
    line-height: 1.12;
  }
  .hero-content p.hero-subtitle {
    font-size: 1rem;
  }
  /* Full-width hero CTAs stack cleanly */
  .hero-content .btn {
    flex: 1 1 100%;
    max-width: 100%;
  }
  .badge {
    font-size: 0.7rem;
    letter-spacing: 0.06em;
    padding: 0.3rem 0.7rem;
  }
  .nav-brand {
    font-size: 0.8rem;
    letter-spacing: 0.02em;
  }
  .nav-actions .btn {
    padding: 0.55rem 0.7rem;
    font-size: 0.75rem;
  }
  /* Compact CTA label so the bar never overflows */
  #navBookCallBtn span {
    display: none;
  }
  #navBookCallBtn::before {
    content: "Start";
  }
  .footer-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  .footer-top .btn {
    align-self: flex-start;
  }
  .project-preview {
    height: 180px;
  }
  .delivery-step-card,
  .glass-card,
  .estimator-box,
  .contact-form-card {
    padding: 1.15rem;
  }
  .modal-box {
    padding: 1.4rem;
  }
}

@media (max-width: 360px) {
  .nav-brand {
    font-size: 0.72rem;
  }
  .nav-actions .btn {
    padding: 0.5rem 0.6rem;
    font-size: 0.7rem;
  }
  .mobile-menu-toggle {
    width: 30px;
    height: 30px;
    font-size: 1.1rem;
  }
  .hero-content h1 {
    font-size: 1.85rem;
  }
}

/* Short landscape screens (phones held sideways) */
@media (max-height: 500px) and (orientation: landscape) {
  html {
    scroll-padding-top: 80px;
  }
  .hero-section {
    padding-top: 6.5rem;
    padding-bottom: 3rem;
    min-height: 0;
  }
}

/* Touch devices: hover states should not stick after a tap */
@media (hover: none) {
  .glass-card:hover,
  .project-card:hover,
  .delivery-step-card:hover,
  .domain-tag-item:hover {
    transform: none;
  }
  .project-card:hover .project-img-wrapper img {
    transform: none;
  }
}
