/* ============================================================
   Hussein Maghrabi — Personal Portfolio
   Handcrafted CSS
   ============================================================ */

:root {
  --bg: #050505;
  --bg-elevated: #111111;
  --bg-card: #181818;
  --text: #ffffff;
  --text-muted: #BDBDBD;
  --primary: #5E6BFF;
  --primary-btn: #4A56F0;
  --primary-soft: rgba(94, 107, 255, 0.15);
  --violet: #8B5CF6;
  --cyan: #06B6D4;
  --green: #10B981;
  --amber: #F59E0B;
  --pink: #EC4899;
  --orange: #F97316;
  --border: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(255, 255, 255, 0.11);
  --glass: rgba(255, 255, 255, 0.03);
  --glass-hover: rgba(255, 255, 255, 0.05);
  --font-display: "Space Grotesk", sans-serif;
  --font-body: "Inter", sans-serif;
  --font-mono: "JetBrains Mono", monospace;
  --max: 80rem;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  scrollbar-width: none;
}

html::-webkit-scrollbar {
  display: none;
}

body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img,
svg {
  display: block;
  max-width: 100%;
}

button,
input,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  background: none;
  border: none;
}

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

ul {
  list-style: none;
}

.container {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: 1.5rem;
}

@media (min-width: 768px) {
  .container {
    padding-inline: 3rem;
  }
}

@media (min-width: 1024px) {
  .container {
    padding-inline: 4rem;
  }
}

/* ------------------------------------------------------------
   Utilities
   ------------------------------------------------------------ */

.glass {
  background: var(--glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border);
}

.glass:hover {
  background: var(--glass-hover);
  border-color: var(--border-hover);
}

.section {
  position: relative;
  padding-block: 8rem;
}

@media (min-width: 768px) {
  .section {
    padding-block: 10rem;
  }
}

.section-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 1rem;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  line-height: 1.1;
  font-size: clamp(2.2rem, 5vw, 3.8rem);
}

.section-title .muted {
  color: var(--text-muted);
}

.section-title .gradient {
  background: linear-gradient(90deg, var(--primary), var(--violet));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.section-lead {
  font-family: var(--font-body);
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
  max-width: 24rem;
  opacity: 0.8;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.875rem 1.5rem;
  border-radius: 999px;
  font-family: var(--font-body);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text);
  text-decoration: none;
  transition: all 0.3s var(--ease);
}

.btn-primary {
  background: var(--primary-btn);
  color: #ffffff;
  box-shadow: 0 0 30px rgba(94, 107, 255, 0.3);
}

.btn-primary:hover {
  gap: 0.75rem;
}

.btn-ghost {
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.05);
}

.chip {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 0.25rem 0.625rem;
  border-radius: 999px;
  color: var(--text-muted);
  transition: all 0.25s var(--ease);
}

.chip-hover:hover {
  transform: translateY(-3px);
  background: rgba(94, 107, 255, 0.15) !important;
  border-color: rgba(94, 107, 255, 0.35) !important;
  color: #fff !important;
}

.icon {
  width: 1em;
  height: 1em;
  flex-shrink: 0;
}

/* ------------------------------------------------------------
   Animations
   ------------------------------------------------------------ */

@keyframes float-a {
  0%, 100% { transform: translateY(0) translateX(0); }
  33% { transform: translateY(-18px) translateX(8px); }
  66% { transform: translateY(6px) translateX(-6px); }
}

@keyframes float-b {
  0%, 100% { transform: translateY(0) translateX(0); }
  40% { transform: translateY(14px) translateX(-10px); }
  70% { transform: translateY(-10px) translateX(4px); }
}

@keyframes float-c {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-20px); }
}

@keyframes float-d {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-14px) rotate(8deg); }
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

@keyframes fade-up {
  from { opacity: 0; transform: translateY(40px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fade-left {
  from { opacity: 0; transform: translateX(32px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes scale-in {
  from { opacity: 0; transform: scale(0.88); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes pulse-ring {
  0% { transform: scale(1); opacity: 0.6; }
  100% { transform: scale(1.6); opacity: 0; }
}

@keyframes gradient-shift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

@keyframes ticker {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.anim-fade-up {
  animation: fade-up 0.85s var(--ease) both;
}

.anim-scale-in {
  animation: scale-in 0.9s var(--ease) both;
}

.cursor-blink {
  animation: blink 1.1s step-end infinite;
}

.reveal,
.reveal-left,
.reveal-right,
.reveal-scale {
  opacity: 0;
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal { transform: translateY(36px); }
.reveal-left { transform: translateX(-40px); }
.reveal-right { transform: translateX(40px); }
.reveal-scale { transform: scale(0.9); }

.reveal.revealed,
.reveal-left.revealed,
.reveal-right.revealed,
.reveal-scale.revealed {
  opacity: 1;
  transform: none;
}

.timeline-line {
  stroke-dasharray: 600;
  stroke-dashoffset: 600;
  transition: stroke-dashoffset 1.4s var(--ease);
}

.timeline-line.drawn {
  stroke-dashoffset: 0;
}

.portrait-ring {
  animation: spin 6s linear infinite;
}

.closing-bg {
  background: linear-gradient(135deg, #050505 0%, #0d0d1a 40%, #090912 70%, #050505 100%);
  background-size: 300% 300%;
  animation: gradient-shift 8s ease infinite;
}

.ticker-wrap {
  overflow: hidden;
}

.ticker-inner {
  display: flex;
  white-space: nowrap;
  animation: ticker 28s linear infinite;
  width: max-content;
}

/* ------------------------------------------------------------
   Mouse glow
   ------------------------------------------------------------ */

.mouse-glow {
  pointer-events: none;
  position: fixed;
  z-index: 0;
  width: 720px;
  height: 720px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(94, 107, 255, 0.065) 0%, transparent 65%);
  transform: translate(-50%, -50%);
  transition: left 0.14s ease-out, top 0.14s ease-out;
}

/* ------------------------------------------------------------
   Navigation
   ------------------------------------------------------------ */

.nav {
  position: fixed;
  top: 1rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-inline: 1.25rem;
  height: 3.5rem;
  width: min(940px, calc(100vw - 32px));
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  transition: all 0.5s;
}

.nav.scrolled {
  width: min(820px, calc(100vw - 32px));
  background: rgba(8, 8, 8, 0.9);
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.5);
}

.nav-logo {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  line-height: 0;
}

.nav-logo img {
  display: block;
  height: 1.75rem;
  width: auto;
}

@media (min-width: 768px) {
  .nav-logo img {
    height: 2rem;
  }
}

.nav-logo span {
  color: var(--primary);
}

.nav-links {
  display: none;
  align-items: center;
  gap: 0.25rem;
}

@media (min-width: 768px) {
  .nav-links {
    display: flex;
  }
}

.nav-link {
  position: relative;
  padding: 0.375rem 0.875rem;
  border-radius: 999px;
  font-size: 0.875rem;
  font-family: var(--font-body);
  color: var(--text-muted);
  transition: color 0.2s;
}

.nav-link.active {
  color: var(--text);
}

.nav-link.active::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: rgba(94, 107, 255, 0.15);
}

.nav-link span {
  position: relative;
}

.nav-cta {
  display: none;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  font-family: var(--font-body);
  color: #ffffff;
  background: var(--primary-btn);
  box-shadow: 0 0 20px rgba(94, 107, 255, 0.25);
  flex-shrink: 0;
  transition: opacity 0.2s;
}

.nav-cta:hover {
  opacity: 0.8;
}

@media (min-width: 768px) {
  .nav-cta {
    display: flex;
  }
}

.nav-toggle {
  display: flex;
  color: var(--text);
  padding: 0.25rem;
}

@media (min-width: 768px) {
  .nav-toggle {
    display: none;
  }
}

.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 2.5rem;
  background: rgba(5, 5, 5, 0.97);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-16px);
  transition: all 0.3s;
}

.mobile-menu.open {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}

@media (min-width: 768px) {
  .mobile-menu {
    display: none;
  }
}

.mobile-menu a {
  font-family: var(--font-display);
  font-size: 1.875rem;
  font-weight: 600;
  color: var(--text);
  transition: color 0.2s;
}

.mobile-menu a:hover {
  color: var(--primary);
}

/* ------------------------------------------------------------
   Hero
   ------------------------------------------------------------ */

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.026) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.026) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 90% 80% at 50% 50%, black 0%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 90% 80% at 50% 50%, black 0%, transparent 100%);
}

.particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.particle {
  position: absolute;
  border-radius: 50%;
}

.hero-blob-a {
  position: absolute;
  pointer-events: none;
  top: 8%;
  left: 28%;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(94, 107, 255, 0.09) 0%, transparent 70%);
  filter: blur(60px);
}

.hero-blob-b {
  position: absolute;
  pointer-events: none;
  bottom: 0;
  right: 10%;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.07) 0%, transparent 70%);
  filter: blur(50px);
}

.hero-inner {
  position: relative;
  z-index: 10;
  width: 100%;
  padding-top: 7rem;
  padding-bottom: 5rem;
}

.hero-layout {
  display: grid;
  gap: 4rem;
  align-items: center;
}

@media (min-width: 1024px) {
  .hero-layout {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  align-self: flex-start;
  padding: 0.375rem 0.875rem;
  border-radius: 999px;
  margin-bottom: 2.5rem;
  background: rgba(94, 107, 255, 0.08);
  border: 1px solid rgba(94, 107, 255, 0.22);
  animation-delay: 0ms;
}

.hero-badge-dot {
  width: 0.375rem;
  height: 0.375rem;
  border-radius: 50%;
  background: var(--primary);
  animation: pulse 2s ease infinite;
}

.hero-badge span:last-child {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  line-height: 1;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
  font-size: clamp(3.2rem, 7vw, 5.8rem);
  animation-delay: 80ms;
}

.hero-title .soft {
  background: linear-gradient(135deg, #ffffff 30%, rgba(255, 255, 255, 0.55));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-role {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 500;
  margin-bottom: 2rem;
  min-height: 2rem;
  color: var(--primary);
  animation-delay: 160ms;
}

@media (min-width: 768px) {
  .hero-role {
    font-size: 1.25rem;
  }
}

.hero-lead {
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.6;
  margin-bottom: 0.75rem;
  max-width: 32rem;
  color: var(--text);
  font-size: clamp(1rem, 2vw, 1.2rem);
  animation-delay: 240ms;
}

.hero-sub {
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.6;
  margin-bottom: 3rem;
  max-width: 32rem;
  color: var(--text-muted);
  font-size: clamp(0.9rem, 1.5vw, 1rem);
  animation-delay: 320ms;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 4rem;
  animation-delay: 400ms;
}

.hero-socials {
  display: flex;
  align-items: center;
  gap: 1rem;
  animation-delay: 480ms;
}

.social-btn {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.2s;
}

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

.hero-portrait-wrap {
  display: flex;
  justify-content: center;
  animation-delay: 200ms;
}

@media (min-width: 1024px) {
  .hero-portrait-wrap {
    justify-content: flex-end;
  }
}

.portrait-stage {
  position: relative;
  /* room for floating tags on small screens */
  margin-inline: 0.75rem;
}

@media (min-width: 640px) {
  .portrait-stage {
    margin-inline: 0;
  }
}

.portrait-glow {
  position: absolute;
  inset: -2rem;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle, rgba(94, 107, 255, 0.12) 0%, transparent 70%);
  filter: blur(20px);
}

.portrait {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.portrait--lg {
  display: none;
  width: 420px;
  height: 420px;
}

.portrait--sm {
  width: 260px;
  height: 260px;
}

@media (min-width: 640px) {
  .portrait--lg {
    display: flex;
  }
  .portrait--sm {
    display: none;
  }
}

.portrait-ring-el {
  position: absolute;
  inset: -3px;
  padding: 3px;
  border-radius: 50%;
  background: conic-gradient(from 180deg, #5E6BFF 0%, #8B5CF6 30%, #EC4899 60%, #5E6BFF 100%);
}

.portrait-ring-el::after {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: var(--bg);
}

.portrait-face {
  position: relative;
  border-radius: 50%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #111111 0%, #181818 50%, #111111 100%);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.portrait-face picture {
  width: 100%;
  height: 100%;
  display: block;
}

.portrait-face img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 18%;
  display: block;
}

.portrait--lg .portrait-face {
  width: 412px;
  height: 412px;
}

.portrait--sm .portrait-face {
  width: 252px;
  height: 252px;
}

.portrait-silhouette {
  width: 75%;
  opacity: 0.18;
}

.portrait-initials {
  position: absolute;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  user-select: none;
  background: linear-gradient(135deg, #5E6BFF, #8B5CF6);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  bottom: 18%;
  line-height: 1;
}

.portrait--lg .portrait-initials {
  font-size: calc(420px * 0.22);
}

.portrait--sm .portrait-initials {
  font-size: calc(260px * 0.22);
}

.portrait-dot {
  position: absolute;
  border-radius: 50%;
}

.portrait-dot-1 {
  width: 16px;
  height: 16px;
  background: var(--primary);
  top: 12%;
  right: 8%;
  box-shadow: 0 0 20px rgba(94, 107, 255, 0.7);
  animation: float-a 4s ease-in-out infinite;
}

.portrait-dot-2 {
  width: 10px;
  height: 10px;
  background: var(--violet);
  bottom: 18%;
  left: 6%;
  box-shadow: 0 0 14px rgba(139, 92, 246, 0.6);
  animation: float-b 5s ease-in-out 1s infinite;
}

.portrait-dot-3 {
  width: 6px;
  height: 6px;
  background: var(--pink);
  top: 38%;
  left: -4%;
  box-shadow: 0 0 10px rgba(236, 72, 153, 0.5);
  animation: float-c 3.5s ease-in-out 0.5s infinite;
}

.float-card {
  position: absolute;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.65rem;
  border-radius: 0.75rem;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.4);
  max-width: 9.5rem;
}

.float-card-icon {
  width: 1.5rem;
  height: 1.5rem;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: rgba(94, 107, 255, 0.2);
  color: var(--primary);
}

.float-card-icon svg {
  width: 12px;
  height: 12px;
}

.float-card-title {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  font-size: 0.75rem;
  line-height: 1;
}

.float-card-sub {
  font-family: var(--font-body);
  color: var(--text-muted);
  font-size: 0.625rem;
  margin-top: 0.1rem;
}

.float-card-a {
  bottom: 6%;
  left: -4%;
  animation: float-a 5s ease-in-out 0.5s infinite;
}

.float-card-b {
  top: 8%;
  right: -4%;
  animation: float-b 4.5s ease-in-out 1s infinite;
}

@media (min-width: 640px) {
  .float-card {
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-radius: 1rem;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4);
    max-width: none;
  }

  .float-card-icon {
    width: 2rem;
    height: 2rem;
    border-radius: 0.75rem;
  }

  .float-card-icon svg {
    width: 15px;
    height: 15px;
  }

  .float-card-title {
    font-size: 0.875rem;
  }

  .float-card-sub {
    font-size: 0.75rem;
    margin-top: 0.125rem;
  }

  .float-card-a {
    bottom: 12%;
    left: -10%;
  }

  .float-card-b {
    top: 14%;
    right: -8%;
  }
}

.scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.scroll-hint span {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--text-muted);
  opacity: 0.4;
}

.scroll-hint-line {
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, var(--text-muted), transparent);
  opacity: 0.3;
  animation: float-c 1.8s ease-in-out infinite;
}

.scroll-hint svg {
  color: var(--text-muted);
  opacity: 0.3;
  width: 12px;
  height: 12px;
}

/* ------------------------------------------------------------
   About
   ------------------------------------------------------------ */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 6rem;
}

@media (min-width: 768px) {
  .stats-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .stats-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

.stat-card {
  border-radius: 1.5rem;
  padding: 1.5rem;
  transition: transform 0.3s;
}

.stat-card:hover {
  transform: translateY(-4px);
}

.stat-value {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  line-height: 1;
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  margin-bottom: 0.25rem;
}

.stat-value--text {
  white-space: nowrap;
  font-size: clamp(1.35rem, 2.2vw, 1.85rem);
  letter-spacing: -0.03em;
}

.stat-label {
  font-family: var(--font-body);
  color: var(--text-muted);
  font-size: 0.875rem;
  line-height: 1.375;
  margin-top: 0.5rem;
}

.stat-rule {
  margin-top: 0.75rem;
  height: 1px;
  width: 2rem;
  background: var(--primary);
  opacity: 0.6;
}

.about-grid {
  display: grid;
  gap: 3rem;
  align-items: start;
}

@media (min-width: 1024px) {
  .about-grid {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
  }
}

.about-photo-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

@media (min-width: 1024px) {
  .about-photo-col {
    align-items: flex-start;
  }
}

.about-photo {
  width: 100%;
  max-width: 24rem;
  border-radius: 1.5rem;
  overflow: hidden;
  position: relative;
  aspect-ratio: 4 / 5;
  background: linear-gradient(145deg, #111111 0%, #181818 60%, #111111 100%);
  border: 1px solid rgba(255, 255, 255, 0.07);
}

.about-photo-fade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 50%, rgba(5, 5, 5, 0.9) 100%);
  z-index: 2;
}

.about-photo-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(94, 107, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(94, 107, 255, 0.04) 1px, transparent 1px);
  background-size: 32px 32px;
  z-index: 1;
  pointer-events: none;
}

.about-photo-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  z-index: 0;
}

.about-photo picture {
  position: absolute;
  inset: 0;
  display: block;
  z-index: 0;
}

.about-photo picture .about-photo-img {
  position: absolute;
}

.about-photo-sil {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 2.5rem;
  z-index: 1;
}

.about-photo-sil svg {
  width: 70%;
  opacity: 0.12;
}

.about-photo-aa {
  position: absolute;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 8rem;
  bottom: 8%;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, rgba(94, 107, 255, 0.35), rgba(139, 92, 246, 0.25));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  z-index: 3;
  line-height: 1;
  letter-spacing: -0.05em;
  user-select: none;
}

.about-photo-meta {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1.5rem;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  z-index: 4;
}

.about-photo-meta h3 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--text);
  font-size: 1.125rem;
  line-height: 1.25;
}

.about-photo-meta p {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--primary);
  margin-top: 0.25rem;
}

.about-photo-arrow {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: rgba(94, 107, 255, 0.15);
  border: 1px solid rgba(94, 107, 255, 0.25);
  color: var(--primary);
}

.about-facts {
  width: 100%;
  max-width: 24rem;
  border-radius: 1rem;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.about-fact {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

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

.about-fact dd {
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text);
}

.about-copy {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.about-bio {
  font-size: 1.05rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 0.5rem;
}

.about-bio-soft {
  font-size: 0.95rem;
  color: rgba(189, 189, 189, 0.7);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.bio-cards {
  display: grid;
  gap: 0.75rem;
}

@media (min-width: 640px) {
  .bio-cards {
    grid-template-columns: 1fr 1fr;
  }
}

.bio-card {
  border-radius: 1rem;
  padding: 1.25rem;
  transition: transform 0.3s;
}

.bio-card:hover {
  transform: translateY(-2px);
}

.bio-card-icon {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  background: rgba(94, 107, 255, 0.1);
  color: var(--primary);
  transition: transform 0.3s;
}

.bio-card:hover .bio-card-icon {
  transform: scale(1.1);
}

.bio-card h4 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--text);
  font-size: 0.875rem;
  margin-bottom: 0.5rem;
  line-height: 1.25;
}

.bio-card p {
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ------------------------------------------------------------
   Expertise
   ------------------------------------------------------------ */

.expertise {
  overflow: hidden;
}

.expertise-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 0%, rgba(20, 20, 40, 0.4) 50%, transparent 100%);
}

.expertise-blob-a {
  position: absolute;
  pointer-events: none;
  top: 10%;
  right: 5%;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(94, 107, 255, 0.06) 0%, transparent 70%);
  filter: blur(40px);
  animation: float-b 8s ease-in-out infinite;
}

.expertise-blob-b {
  position: absolute;
  pointer-events: none;
  bottom: 15%;
  left: 2%;
  width: 220px;
  height: 220px;
  border-radius: 60px;
  border: 1px solid rgba(94, 107, 255, 0.08);
  animation: float-d 7s ease-in-out 2s infinite;
}

.expertise-header {
  margin-bottom: 4rem;
}

.expertise-header-row {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (min-width: 768px) {
  .expertise-header-row {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
  }
}

.expertise-grid {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 768px) {
  .expertise-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 1024px) {
  .expertise-grid {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

.expertise-card {
  border-radius: 1.5rem;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  min-height: 320px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
  transition: transform 0.35s var(--ease), box-shadow 0.35s ease;
}

.expertise-card.tall {
  min-height: 400px;
}

.expertise-card:hover {
  transform: translateY(-10px);
}

.expertise-card-glow {
  position: absolute;
  pointer-events: none;
  top: -60px;
  right: -60px;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  opacity: 0.4;
  transition: opacity 0.5s;
}

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

.expertise-card-shape {
  position: absolute;
  pointer-events: none;
  bottom: -20px;
  left: -20px;
  width: 120px;
  height: 120px;
  border-radius: 32px;
  opacity: 0.2;
  transition: all 0.7s;
}

.expertise-card:hover .expertise-card-shape {
  opacity: 0.6;
  transform: rotate(20deg) scale(1.1);
}

.expertise-card-icon {
  position: relative;
  z-index: 10;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  transition: all 0.3s;
}

.expertise-card:hover .expertise-card-icon {
  transform: scale(1.05);
}

.expertise-card h3 {
  position: relative;
  z-index: 10;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  line-height: 1.25;
}

.expertise-card > p {
  position: relative;
  z-index: 10;
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
  flex: 1;
  margin-bottom: 1.5rem;
}

.expertise-tags {
  position: relative;
  z-index: 10;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.expertise-arrow {
  position: absolute;
  top: 1.75rem;
  right: 1.75rem;
  opacity: 0;
  transform: translate(-4px, 4px);
  transition: all 0.3s;
}

.expertise-card:hover .expertise-arrow {
  opacity: 1;
  transform: none;
}

/* ------------------------------------------------------------
   Projects
   ------------------------------------------------------------ */

.projects {
  overflow: hidden;
}

.projects-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 0%, rgba(10, 10, 25, 0.5) 50%, transparent 100%);
}

.projects-blob {
  position: absolute;
  pointer-events: none;
  top: 20%;
  right: -5%;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(94, 107, 255, 0.05) 0%, transparent 70%);
  filter: blur(60px);
}

.projects-header {
  margin-bottom: 5rem;
}

.projects-header-row {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (min-width: 768px) {
  .projects-header-row {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
  }
}

.projects-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.project-card {
  border-radius: 1.5rem;
  overflow: hidden;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.06);
  transition: transform 0.5s;
  margin-bottom: 25px;
}

.project-card:hover {
  transform: translateY(-8px);
}

.projects-list > .reveal + .reveal {
  margin-top: -2rem;
}

.project-inner {
  display: flex;
  flex-direction: column;
  min-height: 480px;
}

@media (min-width: 1024px) {
  .project-inner {
    flex-direction: row;
  }

  .project-inner.reverse {
    flex-direction: row-reverse;
  }
}

.project-visual {
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
  min-height: 280px;
}

@media (min-width: 1024px) {
  .project-visual {
    width: 45%;
  }
}

.project-visual-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.project-parallax {
  position: absolute;
  inset: 0;
  transform: scale(1.1);
  will-change: transform;
}

.project-visual-content {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.project-visual-inner {
  position: relative;
}

.project-visual-inner--shot {
  position: absolute;
  inset: 0;
}

.project-shot {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
  z-index: 1;
  cursor: zoom-in;
}

.project-shot-fallback {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.project-shot-scrim {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    linear-gradient(to top, rgba(5, 5, 5, 0.55) 0%, transparent 28%),
    linear-gradient(to bottom, rgba(5, 5, 5, 0.2) 0%, transparent 18%);
}

.project-id-huge {
  position: absolute;
  z-index: 5;
  left: 1.25rem;
  bottom: 3.25rem;
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(3rem, 6vw, 4.5rem);
  line-height: 1;
  color: #fff;
  opacity: 0.2;
  letter-spacing: -0.05em;
  pointer-events: none;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.35);
}

.project-num,
.project-cat {
  z-index: 6;
}

.project-fade {
  position: absolute;
  inset-block: 0;
  width: 5rem;
  pointer-events: none;
  z-index: 3;
}

.project-fade.right {
  right: 0;
  background: linear-gradient(to right, transparent, rgba(17, 17, 17, 0.95));
}

.project-fade.left {
  left: 0;
  background: linear-gradient(to left, transparent, rgba(17, 17, 17, 0.95));
}

.project-num {
  position: absolute;
  top: 1.5rem;
  left: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 0.35rem 0.65rem;
  border-radius: 0.5rem;
  background: rgba(5, 5, 5, 0.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.project-cat {
  position: absolute;
  bottom: 1.5rem;
  left: 1.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 0.375rem 0.75rem;
  border-radius: 999px;
  color: var(--text-muted);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.project-body {
  flex: 1;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

@media (min-width: 768px) {
  .project-body {
    padding: 2.5rem;
  }
}

.project-body h3 {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
  margin-bottom: 1.5rem;
  font-size: clamp(1.5rem, 3vw, 2rem);
}

.project-sections {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.project-section-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  margin-bottom: 0.375rem;
}

.project-section-text {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.project-stack-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  margin-bottom: 0.5rem;
}

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

.project-stack span {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  padding: 0.25rem 0.625rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
}

.project-impact {
  padding: 1rem;
  border-radius: 1rem;
}

.project-impact-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  margin-bottom: 0.375rem;
}

.project-impact p {
  font-size: 0.875rem;
  color: var(--text);
  line-height: 1.6;
  font-weight: 500;
  display: -webkit-box;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ------------------------------------------------------------
   Experience
   ------------------------------------------------------------ */

.experience {
  overflow: hidden;
}

.experience-blob {
  position: absolute;
  pointer-events: none;
  top: 30%;
  right: 0;
  width: 350px;
  height: 350px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(94, 107, 255, 0.05) 0%, transparent 70%);
  filter: blur(50px);
}

.experience-grid {
  display: grid;
  gap: 4rem;
}

@media (min-width: 1024px) {
  .experience-grid {
    grid-template-columns: 1fr 1fr;
    gap: 6rem;
  }
}

.timeline-item {
  position: relative;
  display: flex;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .timeline-item {
    gap: 2.5rem;
  }
}

.timeline-rail {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  width: 28px;
}

.timeline-dot {
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  border: 2px solid;
  flex-shrink: 0;
  position: relative;
  z-index: 10;
  background: var(--bg);
  margin-top: 4px;
  transition: box-shadow 0.5s;
}

.timeline-pulse {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  opacity: 0;
}

.timeline-pulse.active {
  animation: pulse-ring 1.5s ease-out 1;
}

.timeline-svg {
  margin-top: 0.25rem;
  flex: 1;
  min-height: 100px;
}

.timeline-card-wrap {
  flex: 1;
  padding-bottom: 3rem;
}

.timeline-period {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  margin-bottom: 0.5rem;
  opacity: 0;
  transform: translateY(12px);
  transition: all 0.5s;
}

.timeline-period.visible {
  opacity: 1;
  transform: none;
}

.timeline-card {
  border-radius: 1rem;
  padding: 1.5rem;
  opacity: 0;
  transform: translateX(-24px);
  transition: all 0.5s, transform 0.35s var(--ease);
}

.timeline-card.visible {
  opacity: 1;
  transform: none;
}

.timeline-card:hover {
  transform: translateY(-4px);
}

.timeline-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.timeline-company {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  font-size: 1.125rem;
  line-height: 1.25;
}

.timeline-role {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  margin-top: 0.125rem;
}

.timeline-check {
  width: 2rem;
  height: 2rem;
  border-radius: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.timeline-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.timeline-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.stack-block {
  margin-top: 0;
}

@media (min-width: 1024px) {
  .stack-block {
    margin-top: 0;
  }
}

.stack-block .section-label {
  margin-bottom: 1rem;
}

.stack-title {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  font-size: 1.5rem;
  margin-bottom: 2.5rem;
}

.stack-groups {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.stack-group-head {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.stack-group-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
}

.stack-group-line {
  flex: 1;
  height: 1px;
}

.stack-items {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
}

.stack-items .chip {
  font-family: var(--font-body);
  font-size: 0.875rem;
  padding: 0.5rem 1rem;
}

/* ------------------------------------------------------------
   Leadership
   ------------------------------------------------------------ */

.leadership {
  overflow: hidden;
}

.leadership-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 0%, rgba(12, 12, 28, 0.6) 50%, transparent 100%);
}

.leadership-blob {
  position: absolute;
  pointer-events: none;
  top: 20%;
  left: 5%;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(94, 107, 255, 0.06) 0%, transparent 70%);
  filter: blur(50px);
}

.leadership-header {
  margin-bottom: 4rem;
}

.leadership-header-row {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

@media (min-width: 768px) {
  .leadership-header-row {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
  }
}

.leadership-layout {
  display: grid;
  gap: 2rem;
}

@media (min-width: 1024px) {
  .leadership-layout {
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
  }
}

.leader-cards {
  display: grid;
  gap: 1rem;
}

@media (min-width: 640px) {
  .leader-cards {
    grid-template-columns: 1fr 1fr;
  }
}

.leader-card {
  border-radius: 1rem;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.35s var(--ease), box-shadow 0.35s ease;
}

.leader-card:hover {
  transform: translateY(-8px);
}

.leader-card-icon {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.25rem;
  transition: all 0.3s;
}

.leader-card:hover .leader-card-icon {
  transform: scale(1.08);
}

.leader-card h3 {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.leader-card p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
  flex: 1;
}

.leader-card-bar {
  margin-top: 1rem;
  height: 2px;
  border-radius: 999px;
  width: 32px;
  transition: width 0.3s;
}

.leader-card:hover .leader-card-bar {
  width: 100%;
}

.leadership-aside {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.arch-diagram {
  border-radius: 1.5rem;
  padding: 2rem;
  position: relative;
  overflow: hidden;
}

.arch-diagram h3 {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  font-size: 1.125rem;
  margin-bottom: 1.5rem;
}

.arch-diagram h3 span {
  color: var(--text-muted);
}

.arch-diagram svg {
  width: 100%;
  max-height: 300px;
}

.philosophy {
  border-radius: 1rem;
  padding: 1.5rem;
}

.philosophy-label {
  font-family: var(--font-mono);
  color: var(--primary);
  font-size: 0.75rem;
  margin-bottom: 1rem;
}

.philosophy blockquote {
  font-size: 0.875rem;
  color: var(--text);
  line-height: 1.6;
  font-style: italic;
}

.philosophy cite {
  display: block;
  margin-top: 1rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  font-style: normal;
}

.leader-stats {
  border-radius: 1rem;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.leader-stat {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.leader-stat span:first-child {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.leader-stat span:last-child {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.875rem;
  color: var(--primary);
}

/* ------------------------------------------------------------
   Testimonials
   ------------------------------------------------------------ */

.testimonials {
  padding-block: 5rem;
}

.testimonials-grid {
  display: grid;
  gap: 1rem;
}

@media (min-width: 768px) {
  .testimonials-grid {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

.testimonial {
  border-radius: 1.5rem;
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  transition: transform 0.3s;
}

.testimonial:hover {
  transform: translateY(-4px);
}

.testimonial-icon {
  color: var(--primary);
}

.testimonial blockquote {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.6;
  font-style: italic;
  flex: 1;
}

.testimonial-author {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--text);
  font-size: 0.875rem;
}

.testimonial-role {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.125rem;
}

/* ------------------------------------------------------------
   Contact
   ------------------------------------------------------------ */

.contact-grid {
  display: grid;
  gap: 4rem;
}

@media (min-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr 1fr;
    gap: 6rem;
  }
}

.contact-title {
  margin-bottom: 1.5rem;
}

.contact-lead {
  font-size: 1.05rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 2.5rem;
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-muted);
  transition: color 0.2s;
}

.contact-link:hover {
  color: var(--text);
}

.contact-link .icon-wrap {
  color: var(--primary);
}

.contact-link span {
  font-family: var(--font-mono);
  font-size: 0.875rem;
}

.contact-link .arrow {
  opacity: 0;
  transition: opacity 0.2s;
  width: 11px;
  height: 11px;
}

.contact-link:hover .arrow {
  opacity: 1;
}

.contact-form,
.contact-success {
  border-radius: 1.5rem;
  padding: 2rem;
}

.contact-success {
  height: 100%;
  min-height: 320px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.contact-success.hidden,
.contact-form.hidden {
  display: none;
}

.contact-success-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  background: rgba(94, 107, 255, 0.1);
  color: var(--primary);
}

.contact-success h3 {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--text);
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.contact-success p {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.form-field {
  margin-bottom: 1rem;
}

.form-field label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  display: block;
  letter-spacing: 0.025em;
}

.form-field input,
.form-field textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 1rem;
  font-size: 0.875rem;
  font-family: var(--font-body);
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  outline: none;
  transition: border-color 0.2s;
  resize: none;
}

.form-field input::placeholder,
.form-field textarea::placeholder {
  color: #444;
}

.form-field input:focus,
.form-field textarea:focus {
  border-color: rgba(94, 107, 255, 0.5);
}

.form-submit {
  width: 100%;
  padding: 0.875rem;
  border-radius: 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  font-family: var(--font-body);
  color: #ffffff;
  background: var(--primary-btn);
  box-shadow: 0 0 24px rgba(94, 107, 255, 0.2);
  transition: opacity 0.2s, transform 0.2s;
}

.form-submit:hover {
  opacity: 0.85;
}

.form-submit:active {
  transform: scale(0.98);
}

/* ------------------------------------------------------------
   Closing CTA
   ------------------------------------------------------------ */

.closing {
  position: relative;
  overflow: hidden;
  padding-block: 10rem;
}

@media (min-width: 768px) {
  .closing {
    padding-block: 14rem;
  }
}

.closing-glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse 80% 60% at 50% 50%, rgba(94, 107, 255, 0.1) 0%, transparent 70%);
}

.closing-blob-a {
  position: absolute;
  pointer-events: none;
  top: 10%;
  left: 10%;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(94, 107, 255, 0.08) 0%, transparent 70%);
  filter: blur(60px);
  animation: float-a 10s ease-in-out infinite;
}

.closing-blob-b {
  position: absolute;
  pointer-events: none;
  bottom: 10%;
  right: 10%;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.07) 0%, transparent 70%);
  filter: blur(60px);
  animation: float-b 12s ease-in-out 2s infinite;
}

.closing-grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, black 0%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, black 0%, transparent 100%);
}

.closing-inner {
  position: relative;
  z-index: 10;
  max-width: 64rem;
  margin-inline: auto;
  padding-inline: 1.5rem;
  text-align: center;
}

@media (min-width: 768px) {
  .closing-inner {
    padding-inline: 3rem;
  }
}

.closing-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0.875rem;
  border-radius: 999px;
  margin-bottom: 2.5rem;
  border: 1px solid rgba(94, 107, 255, 0.22);
}

.closing-badge span:last-child {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.closing-title {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 2rem;
  font-size: clamp(2.8rem, 8vw, 6.5rem);
}

.closing-title .rainbow {
  background: linear-gradient(135deg, #5E6BFF 0%, #8B5CF6 50%, #EC4899 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.closing-lead {
  font-family: var(--font-body);
  font-weight: 300;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 3.5rem;
  max-width: 42rem;
  margin-inline: auto;
  font-size: clamp(1rem, 2vw, 1.2rem);
}

.closing-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 4rem;
}

.closing-actions .btn-primary {
  box-shadow: 0 0 40px rgba(94, 107, 255, 0.35);
  padding: 1rem 1.75rem;
}

.closing-actions .btn-ghost {
  padding: 1rem 1.75rem;
}

.closing .ticker-wrap {
  opacity: 0.2;
}

.ticker-inner span {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-inline: 1.5rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* ------------------------------------------------------------
   Footer
   ------------------------------------------------------------ */

.footer {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  background: var(--bg);
}

.footer-top {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2rem;
  margin-bottom: 2.5rem;
  padding-block: 3rem;
}

@media (min-width: 768px) {
  .footer-top {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

.footer-brand {
  margin-bottom: 0.45rem;
  line-height: 0;
}

.footer-brand img {
  display: block;
  height: 2rem;
  width: auto;
}

.footer-brand span {
  color: var(--primary);
}

.footer-tagline {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.footer-socials {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.footer-socials a {
  color: var(--text-muted);
  transition: color 0.2s, transform 0.2s;
}

.footer-socials a:hover {
  color: var(--text);
  transform: translateY(-2px);
}

.footer-rule {
  height: 1px;
  margin-bottom: 2rem;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.06), transparent);
}

.footer-bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 3rem;
}

@media (min-width: 768px) {
  .footer-bottom {
    flex-direction: row;
  }
}

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

.footer-legal {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.footer-legal a {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-muted);
  transition: color 0.2s;
}

.footer-legal a:hover {
  color: var(--text);
}

/* ------------------------------------------------------------
   Multi-page: catalog + case study
   ------------------------------------------------------------ */

a.nav-logo {
  text-decoration: none;
}

a.nav-link {
  text-decoration: none;
  color: var(--text-muted);
}

a.nav-link:hover {
  color: var(--text);
}

.project-card--link {
  display: block;
  text-decoration: none;
  color: inherit;
  transition: transform 0.35s var(--ease), border-color 0.35s, box-shadow 0.35s;
}

.project-card--link:hover {
  transform: translateY(-6px);
  box-shadow: 0 24px 60px rgba(94, 107, 255, 0.12);
}

.project-card-cta {
  margin-top: 1.25rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
}

.projects-all-cta {
  display: flex;
  justify-content: center;
  margin-top: 3rem;
}

/* ---- Catalog page ---- */

.page-shell {
  position: relative;
  overflow: hidden;
}

.page-hero {
  position: relative;
  padding-top: 9rem;
  padding-bottom: 3.5rem;
  overflow: hidden;
}

.page-hero .section-title {
  font-size: clamp(2.6rem, 6vw, 4.25rem);
}

.page-hero .section-title .gradient {
  background: linear-gradient(90deg, var(--primary), var(--violet), #EC4899);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.page-hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, black, transparent);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, black, transparent);
  pointer-events: none;
}

.projects-catalog-section {
  position: relative;
  padding-top: 0;
  padding-bottom: 8rem;
}

.projects-catalog {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .projects-catalog {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1100px) {
  .projects-catalog {
    grid-template-columns: repeat(3, 1fr);
  }
}

.catalog-card {
  --accent: var(--primary);
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  border-radius: 1.35rem;
  overflow: hidden;
  transition: transform 0.35s var(--ease), border-color 0.35s, box-shadow 0.35s;
}

.catalog-card:hover {
  transform: translateY(-8px);
  border-color: color-mix(in srgb, var(--accent) 45%, transparent);
  box-shadow: 0 28px 70px color-mix(in srgb, var(--accent) 18%, transparent);
}

.catalog-card-media {
  position: relative;
  aspect-ratio: 16 / 10;
  background:
    radial-gradient(circle at 30% 20%, color-mix(in srgb, var(--accent) 35%, transparent), transparent 55%),
    linear-gradient(145deg, #141414, #080808);
  overflow: hidden;
}

.catalog-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  opacity: 0.88;
  transition: transform 0.6s var(--ease), opacity 0.35s;
}

.catalog-card:hover .catalog-card-media img {
  transform: scale(1.06);
  opacity: 1;
}

.catalog-card-media-fade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(5, 5, 5, 0.75) 100%);
  pointer-events: none;
}

.catalog-card-id {
  position: absolute;
  right: 0.85rem;
  bottom: 0.35rem;
  font-family: var(--font-display);
  font-size: 2.75rem;
  font-weight: 700;
  color: #fff;
  opacity: 0.18;
  line-height: 1;
  z-index: 2;
}

.catalog-card-cat-pill {
  position: absolute;
  top: 0.85rem;
  left: 0.85rem;
  z-index: 2;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  color: #fff;
  background: color-mix(in srgb, var(--accent) 35%, rgba(0, 0, 0, 0.55));
  border: 1px solid color-mix(in srgb, var(--accent) 50%, transparent);
  backdrop-filter: blur(8px);
}

.catalog-card-body {
  padding: 1.25rem 1.35rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  flex: 1;
}

.catalog-card-body h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  line-height: 1.3;
}

.catalog-card-body > p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.55;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

.catalog-card-footer {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 0.35rem;
}

.catalog-card-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.catalog-card-stack span {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  padding: 0.2rem 0.45rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
}

.catalog-card-link {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--accent);
  transition: gap 0.25s;
}

.catalog-card:hover .catalog-card-link {
  color: #fff;
}

/* ---- Case study page ---- */

.project-detail-section {
  position: relative;
  padding-top: 7.5rem;
  padding-bottom: 6rem;
  overflow: hidden;
  --project-accent: var(--primary);
}

.project-page-bg {
  position: absolute;
  inset: 0;
  /* Match home: dark page comes from body (#050505); no opaque fill that lightens or blocks the mouse glow */
  background: transparent;
  pointer-events: none;
  z-index: 0;
}

.project-page-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  pointer-events: none;
  z-index: 0;
  animation: float-a 14s ease-in-out infinite;
}

.project-page-blob-a {
  width: 600px;
  height: 600px;
  top: 8%;
  left: 28%;
  background: radial-gradient(circle, color-mix(in srgb, var(--project-accent) 9%, transparent), transparent 70%);
}

.project-page-blob-b {
  width: 400px;
  height: 400px;
  top: auto;
  bottom: 0;
  right: 10%;
  left: auto;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.07), transparent 70%);
  filter: blur(50px);
  animation-name: float-b;
  animation-duration: 18s;
}

.project-detail-section .particles {
  z-index: 0;
}

.project-detail-inner {
  position: relative;
  z-index: 1;
  max-width: var(--max);
}

.project-back {
  margin-bottom: 1.75rem;
}

.project-detail-hero {
  position: relative;
  padding: 2rem;
  border-radius: 1.75rem;
  margin-bottom: 1.75rem;
  overflow: hidden;
  border-color: color-mix(in srgb, var(--project-accent) 28%, transparent);
  background:
    linear-gradient(145deg, color-mix(in srgb, var(--project-accent) 10%, rgba(24, 24, 24, 0.85)), rgba(12, 12, 16, 0.9));
}

@media (min-width: 768px) {
  .project-detail-hero {
    padding: 2.5rem 2.75rem;
  }
}

@media (min-width: 1024px) {
  .project-detail-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: 2.5rem;
    align-items: center;
    padding: 2.75rem 3rem;
  }

  .project-detail-hero-copy {
    min-width: 0;
  }

  .project-detail-shot {
    margin-top: 0;
  }
}

.project-detail-hero-glow {
  position: absolute;
  width: 22rem;
  height: 22rem;
  top: -6rem;
  right: -4rem;
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--project-accent) 30%, transparent), transparent 70%);
  pointer-events: none;
  filter: blur(10px);
  animation: float-c 12s ease-in-out infinite;
}

.project-detail-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--project-accent) 40%, transparent);
  background: color-mix(in srgb, var(--project-accent) 12%, transparent);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #e2e8f0;
  margin-bottom: 1.1rem;
}

.project-detail-badge-sep {
  opacity: 0.45;
}

.project-detail-hero .section-label {
  color: var(--project-accent);
}

.project-detail-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 4.2vw, 3.6rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  margin: 0.35rem 0 1rem;
  line-height: 1.12;
  background: linear-gradient(135deg, #fff 0%, #fff 55%, color-mix(in srgb, var(--project-accent) 75%, #fff));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.project-detail-lead {
  color: var(--text-muted);
  line-height: 1.7;
  max-width: none;
  font-size: 1.02rem;
}

.project-detail-hero .project-stack {
  margin-top: 1.35rem;
}

.project-detail-hero .project-stack span {
  border-color: color-mix(in srgb, var(--project-accent) 30%, transparent);
  background: color-mix(in srgb, var(--project-accent) 10%, transparent);
}

.project-detail-shot {
  margin-top: 1.85rem;
  border-radius: 1.1rem;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--project-accent) 25%, rgba(255, 255, 255, 0.08));
  background: #0a0a0c;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
}

.project-detail-shot img {
  display: block;
  width: 100%;
  height: auto;
  transition: transform 0.7s var(--ease);
}

.project-detail-shot:hover img {
  transform: scale(1.02);
}

/* ------------------------------------------------------------
   Image lightbox
   ------------------------------------------------------------ */

body.lightbox-open {
  overflow: hidden;
}

.image-lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem 1.25rem;
  background: rgba(0, 0, 0, 0.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  opacity: 0;
  transition: opacity 0.25s ease;
  cursor: zoom-out;
}

.image-lightbox[hidden] {
  display: none !important;
}

.image-lightbox.open {
  opacity: 1;
}

.image-lightbox-img {
  max-width: min(96vw, 1400px);
  max-height: min(82vh, 900px);
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 0.75rem;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.65);
  cursor: default;
}

.image-lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1.1rem;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s;
}

.image-lightbox-close:hover {
  background: rgba(255, 255, 255, 0.16);
}

.image-lightbox-hint {
  margin-top: 1rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: rgba(255, 255, 255, 0.45);
  letter-spacing: 0.04em;
}

[data-lightbox] {
  cursor: zoom-in;
}

.project-shot[data-lightbox] {
  pointer-events: auto;
  z-index: 4;
}

.project-shot-overlay {
  pointer-events: none;
}

.project-detail-grid {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 900px) {
  .project-detail-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .project-detail-block--impact,
  .project-detail-block--arch,
  .project-detail-block--code,
  .project-detail-block--wide {
    grid-column: 1 / -1;
  }
}

.project-detail-block {
  --block-accent: var(--project-accent);
  position: relative;
  padding: 1.6rem 1.75rem 1.7rem;
  border-radius: 1.35rem;
  overflow: hidden;
  transition: transform 0.3s var(--ease), border-color 0.3s;
}

.project-detail-block:hover {
  border-color: color-mix(in srgb, var(--block-accent) 35%, transparent);
}

.project-detail-block-bar {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, var(--block-accent), transparent);
  opacity: 0.9;
}

.project-detail-heading {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  margin-bottom: 0.85rem;
  color: #fff;
  letter-spacing: -0.02em;
}

.project-detail-block--impact {
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--block-accent) 16%, rgba(24, 24, 24, 0.9)), rgba(16, 16, 20, 0.92));
  border-color: color-mix(in srgb, var(--block-accent) 40%, transparent);
  box-shadow: 0 0 40px color-mix(in srgb, var(--block-accent) 12%, transparent);
}

.project-detail-block--impact .project-detail-heading {
  color: var(--block-accent);
}

.project-detail-copy {
  color: var(--text-muted);
  line-height: 1.7;
  font-size: 0.95rem;
}

.project-detail-block--impact .project-detail-copy {
  color: #e8e8f0;
}

.project-detail-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 2.25rem;
}

.project-quality-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 1rem;
}

.project-quality-badges--hero {
  margin-top: 0.95rem;
}

.project-quality-badges span {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.02em;
  padding: 0.28rem 0.7rem;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--project-accent) 30%, rgba(255, 255, 255, 0.1));
  background: color-mix(in srgb, var(--project-accent) 12%, rgba(255, 255, 255, 0.03));
  color: #cbd5e1;
}

.project-snippet {
  margin-top: 0.85rem;
}

.project-snippet + .project-snippet {
  margin-top: 1.25rem;
}

.project-snippet-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 0.75rem;
  margin-bottom: 0.55rem;
}

.project-snippet-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
}

.project-snippet-lang {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--project-accent);
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--project-accent) 35%, transparent);
}

.project-snippet-code {
  margin: 0;
  padding: 1.1rem 1.2rem;
  border-radius: 0.9rem;
  border: 1px solid color-mix(in srgb, var(--project-accent) 20%, rgba(255, 255, 255, 0.06));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--project-accent) 8%, #0a0a0f), #07070a);
  overflow-x: auto;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.project-snippet-code code {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.6;
  color: #d4dff0;
  white-space: pre;
}

.project-arch-grid {
  display: grid;
  gap: 0.9rem;
  margin-top: 0.35rem;
}

@media (min-width: 900px) {
  .project-arch-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.project-arch-card {
  --arch-accent: var(--project-accent);
  padding: 1.1rem;
  border-radius: 1rem;
  border: 1px solid color-mix(in srgb, var(--arch-accent) 28%, rgba(255, 255, 255, 0.06));
  background:
    linear-gradient(160deg, color-mix(in srgb, var(--arch-accent) 12%, rgba(0, 0, 0, 0.45)), rgba(0, 0, 0, 0.4));
  transition: transform 0.3s var(--ease), border-color 0.3s;
}

.project-arch-card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--arch-accent) 55%, transparent);
}

.project-arch-label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--arch-accent);
  margin-bottom: 0.6rem !important;
}

.project-arch-card .project-detail-copy {
  font-size: 0.8rem !important;
  line-height: 1.55 !important;
}

.project-arch-diagram {
  margin: 1.35rem 0 0;
  border-radius: 1rem;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--project-accent) 25%, rgba(255, 255, 255, 0.08));
  background: #050505;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
}

.project-arch-diagram img {
  display: block;
  width: 100%;
  height: auto;
}

/* ------------------------------------------------------------
   Project detail — varied section layouts (match home vocabulary)
   ------------------------------------------------------------ */

.project-detail-sections {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
  margin-top: 0.5rem;
}

.project-detail-sections h3 {
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 2.5vw, 1.75rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0.35rem 0 0.85rem;
  color: #fff;
}

.project-detail-sections .section-label {
  margin-bottom: 0.35rem;
}

/* Impact — philosophy quote */
.pd-impact-inner {
  position: relative;
  padding: 2rem 2.25rem;
  border-radius: 1.5rem;
  overflow: hidden;
  border-color: color-mix(in srgb, var(--block-accent) 40%, transparent);
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--block-accent) 18%, rgba(24, 24, 24, 0.9)), rgba(10, 10, 16, 0.95));
}

.pd-impact-glow {
  position: absolute;
  width: 16rem;
  height: 16rem;
  right: -3rem;
  bottom: -4rem;
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--block-accent) 35%, transparent), transparent 70%);
  pointer-events: none;
}

.pd-impact-quote {
  position: relative;
  z-index: 1;
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 2.2vw, 1.45rem);
  font-weight: 500;
  line-height: 1.55;
  color: #f1f5f9;
  letter-spacing: -0.01em;
  max-width: 52rem;
}

.pd-impact-quote::before {
  content: "“";
  display: block;
  font-size: 3rem;
  line-height: 1;
  color: var(--block-accent);
  opacity: 0.7;
  margin-bottom: 0.25rem;
}

/* Problem / Solution pair */
.pd-pair {
  display: grid;
  gap: 1.15rem;
}

@media (min-width: 900px) {
  .pd-pair {
    grid-template-columns: 1fr 1fr;
  }
}

.pd-pair-card {
  padding: 1.6rem 1.7rem;
  border-radius: 1.35rem;
  transition: transform 0.3s var(--ease), border-color 0.3s;
}

.pd-pair-card:hover {
  transform: translateY(-4px);
}

.pd-pair-card--problem:hover {
  border-color: rgba(245, 158, 11, 0.4);
}

.pd-pair-card--solution:hover {
  border-color: color-mix(in srgb, var(--project-accent) 45%, transparent);
}

.pd-pair-icon {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.pd-pair-icon svg {
  width: 1.1rem;
  height: 1.1rem;
}

/* Code terminal */
.pd-code-head {
  margin-bottom: 1rem;
}

.pd-code-window {
  border-radius: 1.15rem;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--block-accent) 28%, rgba(255, 255, 255, 0.08));
  background: linear-gradient(180deg, #0c0c12, #07070a);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.4);
}

.pd-code-chrome {
  display: flex;
  gap: 0.4rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.02);
}

.pd-code-chrome span {
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
}

.pd-code-chrome span:nth-child(1) { background: #ff5f57; }
.pd-code-chrome span:nth-child(2) { background: #febc2e; }
.pd-code-chrome span:nth-child(3) { background: #28c840; }

.pd-code-window .project-snippet {
  padding: 1rem 1.25rem 1.35rem;
  margin-top: 0;
}

/* Quality stats strip */
.pd-quality {
  display: grid;
  gap: 1.5rem;
  align-items: start;
}

@media (min-width: 900px) {
  .pd-quality {
    grid-template-columns: 1.1fr 0.9fr;
    gap: 2rem;
  }
}

.pd-quality-stats {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.pd-quality-stat {
  position: relative;
  padding: 1rem 1.2rem;
  border-radius: 1rem;
  overflow: hidden;
}

.pd-quality-stat-val {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  color: #fff;
}

.pd-quality-stat-bar {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 3px;
  width: 100%;
  border-radius: 0;
  opacity: 0.9;
}

/* Architecture tiles — expertise-like */
.pd-arch-intro {
  margin-bottom: 1.25rem;
}

.pd-arch-tiles {
  display: grid;
  gap: 1rem;
}

@media (min-width: 900px) {
  .pd-arch-tiles {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.pd-arch-tile {
  --arch-accent: var(--project-accent);
  position: relative;
  padding: 1.5rem 1.4rem 1.6rem;
  border-radius: 1.35rem;
  overflow: hidden;
  transition: transform 0.35s var(--ease), border-color 0.35s;
}

.pd-arch-tile:hover {
  transform: translateY(-6px);
  border-color: color-mix(in srgb, var(--arch-accent) 45%, transparent);
}

.pd-arch-tile-glow {
  position: absolute;
  width: 10rem;
  height: 10rem;
  top: -3rem;
  right: -2rem;
  border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--arch-accent) 25%, transparent), transparent 70%);
  opacity: 0.7;
  pointer-events: none;
}

.pd-arch-tile-icon {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  color: var(--arch-accent);
  background: color-mix(in srgb, var(--arch-accent) 14%, transparent);
  position: relative;
  z-index: 1;
}

.pd-arch-tile h4 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.65rem;
  position: relative;
  z-index: 1;
}

.pd-arch-tile .project-detail-copy {
  font-size: 0.82rem;
  position: relative;
  z-index: 1;
}

.pd-arch-tile-bar {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 3px;
  width: 0;
  background: var(--arch-accent);
  transition: width 0.4s var(--ease);
}

.pd-arch-tile:hover .pd-arch-tile-bar {
  width: 55%;
}

/* Challenges timeline */
.pd-timeline {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.25rem;
  align-items: stretch;
}

.pd-timeline-rail {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 0.35rem;
}

.pd-timeline-dot {
  width: 0.85rem;
  height: 0.85rem;
  border-radius: 50%;
  border: 2px solid var(--block-accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--block-accent) 20%, transparent);
  background: var(--bg);
  flex-shrink: 0;
}

.pd-timeline-line {
  flex: 1;
  width: 2px;
  margin-top: 0.5rem;
  background: linear-gradient(180deg, color-mix(in srgb, var(--block-accent) 50%, transparent), transparent);
  min-height: 4rem;
}

.pd-timeline-card {
  padding: 1.4rem 1.5rem;
  border-radius: 1.25rem;
  margin-top: 0.5rem;
}

/* Technical decision — leadership card */
.pd-decision-card {
  position: relative;
  display: flex;
  gap: 1.25rem;
  padding: 1.75rem 1.75rem 1.85rem;
  border-radius: 1.35rem;
  overflow: hidden;
  transition: transform 0.3s var(--ease), border-color 0.3s;
}

.pd-decision-card:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--block-accent) 40%, transparent);
}

.pd-decision-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.pd-decision-bar {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
}

@media (max-width: 640px) {
  .pd-decision-card {
    flex-direction: column;
  }

  .pd-timeline {
    gap: 0.85rem;
  }
}
