/* Design Tokens - Converted from maxim_styles.json */

:root {
  /* Colors */
  --bg: #111211;
  --fg: #F1F3F5;
  --muted: #A7ABB2;
  --accent: #274133;
  --card: #111316;
  --lines: rgba(255, 255, 255, 0.06);
  --maxw: 1200px;
  
  /* Typography */
  --font-display: 'Russo One', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-body: 'Barlow', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  
  --font-weight-regular: 400;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
  --font-weight-extrabold: 800;
  --font-weight-black: 900;
  
  --line-height-tight: 1.6;
  --line-height-snug: 1.6;
  --line-height-normal: 1.6;
  
  --font-size-display-hero: clamp(2.2rem, 6.2vw, 6rem);
  --font-size-h1: clamp(2rem, 4vw, 3rem);
  --font-size-h2: clamp(1.2rem, 2.2vw, 1.6rem);
  --font-size-h3: 1.15rem;
  --font-size-body: 1rem;
  --font-size-small: 0.9rem;
  
  --letter-spacing-wide: 0.02em;
  --letter-spacing-kicker: 0.08em;
  
  /* Spacing */
  --spacing-0: 0;
  --spacing-1: 0.25rem;
  --spacing-2: 0.5rem;
  --spacing-3: 0.75rem;
  --spacing-4: 1rem;
  --spacing-5: 1.25rem;
  --spacing-6: 1.5rem;
  --spacing-7: 2rem;
  --spacing-8: 3rem;
  --spacing-9: 4rem;
  --spacing-10: 6rem;
  
  /* Radii */
  --radius-sm: 0.6rem;
  --radius-md: 0.8rem;
  --radius-lg: 1rem;
  --radius-pill: 999px;
  
  /* Shadows */
  --shadow-card: 0 10px 30px rgba(0, 0, 0, 0.35);
  
  /* Layout */
  --grid-columns: 12;
  --grid-gap: 1.2rem;
  --breakpoint-md: 960px;
  --breakpoint-sm: 860px;

  --project-thumb-height: 230px;

  /* Nav */
  --nav-height: 64px;
  --nav-radius: 32px;
  --nav-bg: color-mix(in hsl, #0B0C0E 70%, transparent);
  --nav-gap: calc(var(--spacing-7) + 0.35rem);

  --mobile-control-size: 40px;
  --mobile-shell-height: calc(var(--mobile-control-size) + (var(--spacing-3) * 2));
}

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

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: var(--font-body);
  font-size: var(--font-size-body);
  line-height: var(--line-height-normal);
  color: var(--fg);
  background-color: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  position: relative;
  overflow-x: hidden;
  padding-top: calc(var(--nav-height) + var(--spacing-4));
  padding-bottom: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

body.modal-open {
  overflow: hidden;
}

body::before {
  content: '';
  position: absolute;
  top: -65vh;
  left: -5vw;
  width: clamp(520px, 68vw, 880px);
  aspect-ratio: 1;
  background: radial-gradient(circle at 40% 40%, rgba(72, 118, 94, 0.6), rgba(72, 118, 94, 0.32), transparent 70%);
  filter: blur(140px);
  opacity: 0.6;
  z-index: 0;
  pointer-events: none;
  animation: float-orb 16s ease-in-out infinite alternate;
}

body::after {
  content: none;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: var(--font-weight-bold);
  line-height: var(--line-height-normal);
  letter-spacing: var(--letter-spacing-wide);
  color: var(--fg);
}

h1 {
  font-size: var(--font-size-h1);
}

h2 {
  font-size: var(--font-size-h2);
  text-transform: uppercase;
  letter-spacing: var(--letter-spacing-kicker);
}

h3 {
  font-size: var(--font-size-h3);
}

p {
  margin-bottom: var(--spacing-4);
  line-height: var(--line-height-normal);
}

a {
  color: var(--fg);
  text-decoration: none;
  transition: opacity 0.2s ease;
}

a:hover {
  opacity: 0.7;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Navigation */
.nav-rail {
  position: fixed;
  top: var(--spacing-4);
  left: 0;
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--spacing-3);
  padding: 0 var(--spacing-4);
  z-index: 1000;
  overflow: visible;
}

.nav {
  position: relative;
  width: auto;
  z-index: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0;
  height: auto;
  pointer-events: none;
}

.nav-container {
  position: relative;
  width: auto;
  max-width: min(var(--maxw), calc(100% - 1.5rem));
  margin: 0 auto;
  padding: var(--spacing-2) calc(var(--nav-gap) * 0.9);
  min-height: var(--nav-height);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--nav-gap);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.01)),
              radial-gradient(160% 180% at 18% 20%, rgba(255, 255, 255, 0.06), transparent 58%),
              radial-gradient(140% 150% at 80% 10%, rgba(255, 255, 255, 0.05), transparent 50%);
  border-radius: var(--nav-radius);
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px) saturate(130%) contrast(104%);
  -webkit-backdrop-filter: blur(12px) saturate(130%) contrast(104%);
  pointer-events: auto;
}

.nav-container::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background:
    radial-gradient(110% 120% at 12% 22%, rgba(255, 255, 255, 0.14), transparent 55%),
    radial-gradient(120% 140% at 82% 8%, rgba(255, 255, 255, 0.1), transparent 55%);
  filter: blur(10px) saturate(150%);
  opacity: 0.6;
  mix-blend-mode: screen;
  pointer-events: none;
  z-index: 0;
}

.nav-container::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    radial-gradient(130% 150% at 0% 50%, rgba(255, 255, 255, 0.12), transparent 35%),
    radial-gradient(140% 160% at 100% 50%, rgba(255, 255, 255, 0.1), transparent 40%);
  mix-blend-mode: screen;
  opacity: 0.48;
  pointer-events: none;
  z-index: 0;
}

.nav-indicator {
  position: absolute;
  top: 50%;
  left: 0;
  height: 70%;
  min-width: 4rem;
  border-radius: calc(var(--nav-radius) - 10px);
  background: rgba(255, 255, 255, 0.06);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2),
              0 6px 16px rgba(0, 0, 0, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  transform: translateY(-50%);
  transition: left 0.38s ease, width 0.38s ease, opacity 0.25s ease;
  opacity: 0;
  pointer-events: none;
  z-index: 1;
}

.nav-links {
  display: flex;
  gap: var(--nav-gap);
  list-style: none;
  text-transform: uppercase;
  font-size: var(--font-size-small);
  font-weight: var(--font-weight-regular);
  letter-spacing: var(--letter-spacing-kicker);
  align-items: center;
  justify-content: center;
}

.nav-links a {
  color: var(--fg);
  transition: opacity 0.2s ease, color 0.2s ease;
  position: relative;
  padding: 0.18rem 0.2rem;
  display: inline-block;
  z-index: 2;
}

.nav-links a:hover {
  opacity: 1;
}

.nav-actions {
  display: flex;
  align-items: stretch;
  height: 100%;
  z-index: 2;
}

.nav-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--nav-height);
  padding: var(--spacing-2) var(--spacing-6);
  font-size: var(--font-size-small);
  letter-spacing: var(--letter-spacing-kicker);
}

.nav-cta::after {
  content: '';
  position: absolute;
  inset: -45%;
  background: radial-gradient(140% 140% at var(--glow-x, 50%) var(--glow-y, 50%), rgba(70, 132, 104, 0.6), transparent 60%);
  opacity: 0.12;
  transition: opacity 0.25s ease;
  pointer-events: none;
  mix-blend-mode: screen;
}

.nav-cta:hover,
.nav-cta:focus-visible {
  transform: scale(1.02);
  opacity: 1;
}

.nav-cta:hover::after,
.nav-cta:focus-visible::after {
  opacity: 0.4;
}

.nav-cta--outside {
  flex-shrink: 0;
  z-index: 2;
}


.mobile-menu {
  position: fixed;
  bottom: var(--spacing-4);
  left: var(--spacing-4);
  right: var(--spacing-4);
  z-index: 1200;
  display: none;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--spacing-3);
  isolation: isolate;
}

@supports (top: env(safe-area-inset-top)) {
  .mobile-menu {
    bottom: calc(var(--spacing-4) + env(safe-area-inset-bottom));
    left: calc(var(--spacing-4) + env(safe-area-inset-left));
    right: calc(var(--spacing-4) + env(safe-area-inset-right));
  }
}

.mobile-menu-shell {
  position: relative;
  display: inline-flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  gap: 0;
  padding: var(--spacing-3);
  width: fit-content;
  min-height: var(--mobile-shell-height);
  border-radius: 32px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02)),
              radial-gradient(160% 160% at 82% 18%, rgba(255, 255, 255, 0.14), transparent 55%),
              radial-gradient(140% 160% at 25% 50%, rgba(255, 255, 255, 0.12), transparent 60%);
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px) saturate(150%);
  -webkit-backdrop-filter: blur(14px) saturate(150%);
  pointer-events: auto;
  overflow: hidden;
  transform-origin: bottom left;
  will-change: transform, padding, gap, box-shadow, border-radius, min-width;
  transition:
    padding 0.55s cubic-bezier(0.24, 0.82, 0.13, 1),
    gap 0.55s cubic-bezier(0.24, 0.82, 0.13, 1),
    box-shadow 0.6s cubic-bezier(0.19, 1, 0.22, 1),
    border-radius 0.6s cubic-bezier(0.19, 1, 0.22, 1),
    min-width 0.55s cubic-bezier(0.24, 0.82, 0.13, 1),
    transform 0.6s cubic-bezier(0.19, 1, 0.22, 1),
    backdrop-filter 0.65s cubic-bezier(0.19, 1, 0.22, 1),
    -webkit-backdrop-filter 0.65s cubic-bezier(0.19, 1, 0.22, 1),
    filter 0.5s ease;
}

.mobile-menu-bar {
  display: flex;
  justify-content: right;
  align-items: center;
  gap: var(--spacing-3);
  width: 100%;
}

.mobile-menu-shell::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background:
    radial-gradient(140% 160% at 15% 50%, rgba(255, 255, 255, 0.18), transparent 45%),
    radial-gradient(120% 140% at 90% 20%, rgba(255, 255, 255, 0.26), transparent 55%),
    conic-gradient(from 160deg at 80% 50%, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.05));
  filter: blur(16px) saturate(150%);
  opacity: 0.7;
  pointer-events: none;
}

.mobile-menu-toggle {
  position: relative;
  display: grid;
  place-items: center;
  align-content: center;
  cursor: pointer;
  padding: 0;
  width: var(--mobile-control-size);
  height: var(--mobile-control-size);
  border: none;
  background: none;
  color: inherit;
  appearance: none;
  flex-shrink: 0;
}

.mobile-menu-toggle:hover {
  transform: translateY(-1px);
}

.mobile-menu-toggle:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.6);
  outline-offset: 4px;
}

.hamburger-lines {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 20px;
  height: 16px;
  display: inline-block;
  transition: transform 0.45s ease;
}

.hamburger-lines .line {
  position: absolute;
  left: 0;
  right: 0;
  margin: 0 auto;
  width: 100%;
  height: 2px;
  background: currentColor;
  border-radius: var(--radius-pill);
  transition: transform 0.35s ease, opacity 0.3s ease;
}

.hamburger-lines .line:nth-child(1) {
  top: 2px;
}

.hamburger-lines .line:nth-child(2) {
  top: 7px;
}

.hamburger-lines .line:nth-child(3) {
  bottom: 2px;
}

.mobile-menu-toggle.open .line:nth-child(1) {
  transform: translateY(5px) rotate(45deg);
}

.mobile-menu-toggle.open .line:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle.open .line:nth-child(3) {
  transform: translateY(-5px) rotate(-45deg);
}

.mobile-nav-links {
  list-style: none;
  position: relative;
  margin-top: 0;
  margin-bottom: 0;
  padding: 0;
  width: 0;
  background: none;
  border: none;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  display: flex;
  flex-direction: column;
  gap: 0;
  align-items: flex-end;
  text-align: right;
  opacity: 0;
  max-height: 0;
  transform: translateY(-6px);
  pointer-events: none;
  overflow: hidden;
  transform-origin: bottom right;
  filter: blur(12px) saturate(90%);
  will-change: opacity, transform, max-height, margin-bottom, filter;
  transition:
    opacity 0.5s cubic-bezier(0.25, 0.8, 0.25, 1),
    transform 0.55s cubic-bezier(0.21, 0.88, 0.26, 0.99),
    max-height 0.6s cubic-bezier(0.21, 0.88, 0.26, 0.99),
    margin-bottom 0.45s ease,
    filter 0.55s cubic-bezier(0.21, 0.88, 0.26, 0.99);
}

.mobile-nav-links a {
  font-size: var(--font-size-body);
  letter-spacing: var(--letter-spacing-kicker);
  text-transform: uppercase;
  color: var(--fg);
  display: inline-block;
  padding: 0.1rem 0;
  position: relative;
  transition: opacity 0.2s ease;
}

.mobile-nav-links a::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -0.18rem;
  width: 0;
  height: 1px;
  background: currentColor;
  transition: width 0.3s ease, left 0.3s ease;
  opacity: 0.9;
}

.mobile-nav-links a:hover::after,
.mobile-nav-links a:focus-visible::after,
.mobile-nav-links a.active::after {
  width: 100%;
  left: 0;
}

.mobile-menu.open .mobile-menu-shell {
  gap: 0;
  padding: var(--spacing-3);
  min-width: 50%;
  border-radius: 32px;
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  align-items: stretch;
  transform: translateY(2px) scale(1.02);
  backdrop-filter: blur(16px) saturate(165%);
  -webkit-backdrop-filter: blur(16px) saturate(165%);
  filter: drop-shadow(0 12px 28px rgba(0, 0, 0, 0.28));
}

.mobile-menu.open .mobile-nav-links {
  opacity: 1;
  max-height: 500px;
  transform: translateY(0);
  margin-bottom: var(--spacing-2);
  width: 100%;
  padding: 0 var(--spacing-1) var(--spacing-1);
  gap: var(--spacing-3);
  pointer-events: auto;
  filter: blur(0) saturate(110%);
}

.mobile-nav-cta {
  width: auto;
  justify-content: center;
  padding: 0.65rem 1.2rem;
  font-size: var(--font-size-small);
}

.mobile-nav-cta.mobile-nav-cta--outside {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: var(--mobile-shell-height);
  padding: 0 var(--spacing-5);
  line-height: 1.2;
  font-size: var(--font-size-body);
  font-weight: 600;
  flex-shrink: 0;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

.mobile-nav-cta-icon {
  width: 18px;
  height: 18px;
}

/* Container */
.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--spacing-4);
}

/* Hero Section */
.hero {
  padding: clamp(3rem, 8vw, 6rem) 0;
  position: relative;
  overflow: hidden;
  min-height: 60vh;
  display: flex;
  align-items: center;
}

.hero .container {
  position: relative;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 0 var(--spacing-4);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.hero-image-wrapper {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 60vh;
}

.hero-image {
  position: relative;
  width: auto;
  height: 50vh;
  max-height: 450px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: center;
  opacity: 0.75;
  z-index: 1;
  mix-blend-mode: difference;
  filter: grayscale(10%);
  pointer-events: none;
  border-radius: 16px;
  transition: transform 0.1s ease-out;
  will-change: transform;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5), inset 0 0 50px rgba(0, 0, 0, 0.5), inset 0 -25px 70px rgba(0, 0, 0, 0.45);
}

.hero-image-wrapper {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 60vh;
  isolation: isolate;
}

.hero-image::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 30%;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.4) 0%, transparent 100%);
  border-radius: 0 0 16px 16px;
  pointer-events: none;
}


.hero-text-container {
  position: absolute;
  inset: auto 0 4vh 0;
  z-index: 3;
  width: 100%;
  max-width: none;
  background: transparent;
  pointer-events: none;
  mix-blend-mode: difference;
  transform: none;
}

.hero-name-scroll {
  width: 100%;
  overflow: hidden;
  white-space: nowrap;
  margin-bottom: 0;
  position: relative;
  transform: translateY(1.25rem);
}

.scroll-text {
  display: inline-flex;
  animation: scroll-horizontal 35s linear infinite;
  font-family: var(--font-display);
  font-size: clamp(4rem, 15vw, 11rem);
  font-weight: var(--font-weight-black);
  line-height: var(--line-height-tight);
  letter-spacing: 0.08em;
  color: #ddeddd;
  mix-blend-mode: difference;
  text-transform: uppercase;
  position: relative;
  z-index: 3;
  font-kerning: none;
  text-rendering: optimizeSpeed;
}

.scroll-text span {
  display: inline-block;
  padding: 0 var(--spacing-8);
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.08em;
}

@keyframes scroll-horizontal {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(calc(-100% / 3));
  }
}

@keyframes float-orb {
  0% {
    transform: translate3d(-20vw, 2vh, 0) scale(1.02);
  }
  50% {
    transform: translate3d(-12vw, 6vh, 0) scale(0.98);
  }
  100% {
    transform: translate3d(6vw, 4vh, 0) scale(1.04);
  }
}

@keyframes float-orb-bottom {
  0% {
    transform: translate3d(-24vw, -6vh, 0) scale(1.05);
  }
  45% {
    transform: translate3d(4vw, 2vh, 0) scale(0.99);
  }
  100% {
    transform: translate3d(32vw, -3vh, 0) scale(1.08);
  }
}

.skills-strip-scroll {
  width: 100%;
  overflow: hidden;
  white-space: nowrap;
  position: relative;
  margin-top: -0.75rem;
}

.scroll-skills {
  display: inline-flex;
  animation: scroll-horizontal 30s linear infinite;
  font-family: var(--font-body);
  font-size: clamp(1.2rem, 3vw, 2rem);
  font-weight: var(--font-weight-regular);
  line-height: var(--line-height-normal);
  letter-spacing: 0.1em;
  color: #646A63;
  text-transform: lowercase;
  align-items: center;
}

.scroll-skills .skill-item {
  display: inline-block;
  padding: 0 var(--spacing-5);
  white-space: nowrap;
  flex-shrink: 0;
}

.scroll-skills .skill-dash {
  display: inline-block;
  padding: 0 var(--spacing-5);
  white-space: nowrap;
  flex-shrink: 0;
}


/* Sections */
.section {
  padding: var(--spacing-10) 0;
}

.section:first-of-type {
  padding-top: 0;
}

.section-heading {
  font-size: var(--font-size-h2);
  font-weight: var(--font-weight-bold);
  text-transform: uppercase;
  letter-spacing: var(--letter-spacing-kicker);
  margin-bottom: var(--spacing-8);
  color: #ddeddd;
  text-align: center;
}

/*.section-heading::after {
  content: ".";
}*/

.section-subheading {
  font-size: var(--font-size-h3);
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--letter-spacing-kicker);
  color: #ddeddd;
  margin: 0 0 var(--spacing-4);
}

/*.section-subheading::after {
  content: ".";
}*/

/* About Preview */
.about-preview {
  max-width: 800px;
  margin: 0 auto;
  text-align: left;
}

.about-preview .btn {
  margin-top: var(--spacing-4);
}

.about-preview p {
  font-size: var(--font-size-body);
  line-height: var(--line-height-normal);
  color: var(--muted);
  margin-bottom: var(--spacing-6);
}

.about-preview p:first-of-type {
  font-size: var(--font-size-h3);
  color: #fff;
}

.about-preview p:nth-of-type(2) {
  color: rgba(255, 255, 255, 0.8);
}

/* Work Cards */
.work-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--grid-gap);
  margin-bottom: var(--spacing-8);
}

.work-card {
  background: var(--card);
  border: 1px solid var(--lines);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
}

.work-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.45);
  border-color: rgba(255, 255, 255, 0.1);
}

.work-card-image {
  width: 100%;
  aspect-ratio: 16 / 10;
  background: var(--lines);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: var(--font-size-small);
  text-align: center;
  padding: var(--spacing-4);
}

.work-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.work-card-content {
  padding: var(--spacing-4) var(--spacing-5) var(--spacing-6);
}

.work-card-category {
  display: inline-block;
  padding: 0.35rem 0.6rem;
  border: 1px solid var(--lines);
  border-radius: var(--radius-pill);
  font-size: var(--font-size-small);
  color: #D7DBE3;
  margin-bottom: var(--spacing-3);
  text-transform: uppercase;
  letter-spacing: var(--letter-spacing-kicker);
  font-weight: var(--font-weight-semibold);
}

.work-card-title {
  font-size: var(--font-size-h3);
  font-weight: var(--font-weight-bold);
  color: var(--fg);
  margin: 0;
  line-height: var(--line-height-snug);
}

/* Work Desktop */
.work-desktop-section {
  padding: clamp(2rem, 6vw, 3.5rem) 0;
  position: relative;
  isolation: isolate;
}

.desktop-shell {
  position: relative;
  min-height: calc(100vh - var(--nav-height) - clamp(2.4rem, 5vw, 4rem));
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--spacing-4);
  border: none;
  background: transparent;
  box-shadow: none;
}

.desktop-shell__header {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0 0 clamp(0.9rem, 1.8vw, 1.2rem);
  text-align: center;
}

.desktop-shell__title {
  margin: 0;
}

.desktop-stage {
  position: relative;
  z-index: 2;
  min-height: clamp(520px, 70vh, 720px);
  margin-top: clamp(0.8rem, 1.8vw, 1.2rem);
  border-radius: 1rem;
  background: radial-gradient(110% 140% at 24% 28%, rgba(70, 132, 104, 0.14), transparent 52%),
              radial-gradient(90% 120% at 80% 50%, rgba(255, 255, 255, 0.06), transparent 50%),
              rgba(8, 9, 11, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.desktop-panel {
  position: absolute;
  top: var(--panel-top);
  left: var(--panel-left);
  width: clamp(260px, 32vw, 360px);
  background:
    linear-gradient(130deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.05)),
    radial-gradient(160% 180% at 20% 20%, rgba(70, 132, 104, 0.28), transparent 55%),
    radial-gradient(120% 140% at 80% 10%, rgba(255, 255, 255, 0.18), transparent 55%),
    rgba(14, 15, 18, 0.6);
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow:
    0 12px 28px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.15),
    inset 0 -1px 0 rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(16px) saturate(165%);
  -webkit-backdrop-filter: blur(16px) saturate(165%);
  overflow: hidden;
  cursor: grab;
  user-select: none;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
  animation: panel-float 12s ease-in-out infinite alternate;
}

.desktop-panel:active {
  cursor: grabbing;
  transform: translateY(-1px);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.5);
}

.desktop-panel.is-dragging {
  box-shadow: 0 22px 48px rgba(0, 0, 0, 0.55);
  transition: none;
  animation: none;
  transform: translate3d(0, 0, 0);
}

.desktop-panel__bar {
  display: flex;
  align-items: center;
  padding: 0.5rem 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.02));
}

.desktop-panel__title {
  margin: 0;
  font-size: var(--font-size-h3);
  letter-spacing: var(--letter-spacing-kicker);
  text-transform: uppercase;
  color: #ddeddd;
}

.desktop-panel__body {
  display: grid;
  gap: var(--spacing-3);
  padding: var(--spacing-3);
}

.desktop-panel__body img {
  --panel-img-scale: 1;
  width: 100%;
  border-radius: 0.8rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
  transition: transform 0.35s ease, box-shadow 0.35s ease;
  transform: scale(var(--panel-img-scale));
}

.desktop-panel:hover .desktop-panel__body img {
  --panel-img-scale: 1.06;
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.desktop-panel:nth-child(2) {
  animation-duration: 14s;
  animation-delay: -2s;
}

.desktop-panel:nth-child(3) {
  animation-duration: 16s;
  animation-delay: -4s;
}

/* Mobile work list */
.work-mobile-section {
  display: none;
  padding: var(--spacing-8) 0;
  overflow-x: hidden;
}

.mobile-work__list {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-4);
  overflow-x: hidden;
}

.mobile-work-card {
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.18);
  background:
    linear-gradient(130deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.05)),
    radial-gradient(160% 180% at 20% 20%, rgba(70, 132, 104, 0.28), transparent 55%),
    radial-gradient(120% 140% at 80% 10%, rgba(255, 255, 255, 0.18), transparent 55%),
    rgba(14, 15, 18, 0.6);
  box-shadow:
    0 12px 28px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.15),
    inset 0 -1px 0 rgba(255, 255, 255, 0.08);
  pointer-events: auto;
  position: relative;
  overflow: hidden;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.mobile-work-card__bar {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 0.65rem 0.85rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.02));
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.mobile-work-card__bar h3 {
  margin: 0;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-family: var(--font-body);
  font-weight: var(--font-weight-semibold);
  font-size: 1rem;
}

.mobile-work-card__body {
  display: flex;
  flex-direction: column;
  padding: var(--spacing-3);
}

.mobile-work-card__preview {
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.mobile-work-card__preview img {
  width: 100%;
  display: block;
  object-fit: cover;
}

.mobile-work-card__details {
  display: grid;
  gap: var(--spacing-3);
  border-top: 1px solid transparent;
  padding-top: 0;
  margin-top: 0;
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.32s ease;
}

.mobile-work-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-1);
  padding: 0;
  margin: 0;
  list-style: none;
}

.mobile-work-card__tag {
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
}

.mobile-work-card__description {
  display: grid;
  gap: var(--spacing-2);
  margin: 0;
}

.mobile-work-card__description-lead {
  margin: 0;
}

.mobile-work-card__description-extra {
  display: grid;
  gap: var(--spacing-2);
}

.mobile-work-card__description:not(.is-expanded) .mobile-work-card__description-lead {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.mobile-work-card__description:not(.is-expanded) .mobile-work-card__description-extra {
  display: none;
}

.mobile-work-card__read-more {
  justify-self: start;
  border: none;
  background: none;
  color: inherit;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  text-decoration: underline;
  padding: 0;
}

.mobile-work-card__gallery {
  display: grid;
  gap: var(--spacing-2);
}

.mobile-work-card__gallery img {
  width: 100%;
  /*border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);*/
}

.mobile-work-card__footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--spacing-2);
}

.mobile-work-card.is-open {
  transform: translateY(-2px);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.5);
  border-color: rgba(255, 255, 255, 0.26);
}

.mobile-work-card.is-open .mobile-work-card__details {
  margin-top: var(--spacing-3);
  padding-top: var(--spacing-3);
  border-top-color: rgba(255, 255, 255, 0.08);
  max-height: 1600px;
}

@keyframes panel-float {
  0% { transform: translate3d(0, 0, 0); }
  50% { transform: translate3d(8px, -10px, 0); }
  100% { transform: translate3d(-8px, 12px, 0); }
}

@media (max-width: 900px) {
  .desktop-shell {
    width: 100%;
    padding: clamp(0.8rem, 1.6vw, 1.2rem);
  }

  .desktop-stage {
    min-height: 680px;
  }
}

@media (max-width: 720px) {
  .desktop-stage {
    display: grid;
    gap: var(--spacing-4);
    padding: var(--spacing-3);
    border-style: solid;
  }

  .desktop-panel {
    position: relative;
    top: auto;
    left: auto;
    width: 100%;
  }
}

/* Project modal */
.project-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: stretch;
  justify-content: center;
  padding: var(--spacing-7);
  background: color-mix(in hsl, rgba(6, 7, 9, 0.62) 60%, rgba(24, 30, 32, 0.48));
  backdrop-filter: blur(22px) saturate(150%) brightness(102%);
  -webkit-backdrop-filter: blur(22px) saturate(150%) brightness(102%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
  z-index: 2000;
}

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

.project-modal__content {
  position: relative;
  width: min(1100px, 100%);
  max-height: calc(100vh - var(--spacing-7) * 2);
  background: linear-gradient(160deg, rgba(16, 18, 20, 0.9), rgba(12, 13, 15, 0.96));
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-lg);
  box-shadow: 0 28px 64px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  overflow-y: auto;
  padding: clamp(1.4rem, 3vw, 2.2rem);
  transform: translateY(28px);
  opacity: 0;
}

.project-modal.is-active .project-modal__content {
  animation: modal-rise 0.45s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.project-modal__backdrop {
  position: absolute;
  inset: 0;
  background: radial-gradient(120% 140% at 18% 24%, rgba(70, 132, 104, 0.28), transparent 55%),
              radial-gradient(120% 140% at 78% 18%, rgba(255, 255, 255, 0.18), transparent 60%);
  opacity: 0.6;
  filter: blur(4px) saturate(110%);
  pointer-events: none;
}

.project-modal__header {
  text-align: center;
  display: grid;
  gap: var(--spacing-3);
}

.project-modal__title {
  font-size: var(--font-size-h2);
  font-weight: var(--font-weight-bold);
  text-transform: uppercase;
  letter-spacing: var(--letter-spacing-kicker);
  margin: 0 0 var(--spacing-1);
  color: #ddeddd;
  text-align: center;
}

.project-modal__meta {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--spacing-2);
  padding: 0;
  margin: 0 0 var(--spacing-6);
  padding-bottom: var(--spacing-2);
}

.project-modal__pill {
  padding: 0.5rem 1rem;
  background: transparent;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.24);
  font-size: var(--font-size-small);
  color: var(--fg);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.project-modal__summary-row {
  display: flex;
  gap: clamp(1rem, 2vw, 1.6rem);
  align-items: flex-start;
  justify-content: center;
  flex-wrap: wrap;
}

.project-modal__thumb-card {
  margin: 0;
  padding: 0;
  background: none;
  border: none;
  border-radius: 0;
  box-shadow: none;
  max-width: 280px;
  flex: 0 0 auto;
}

.project-modal__thumb {
  width: 100%;
  max-height: var(--project-thumb-height);
  object-fit: cover;
  display: block;
  border-radius: var(--radius-md);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.45);
}

.project-modal__accordion {
  --project-accordion-closed-max: var(--project-thumb-height);
  --project-accordion-open-max: var(--project-thumb-height);
  --project-accordion-description-max: var(--project-thumb-height);
  --project-accordion-description-open-max: var(--project-thumb-height);
  --project-accordion-lines: 6;
  flex: 1 1 320px;
  background: none;
  border: none;
  border-radius: 0;
  padding: clamp(0.75rem, 1.4vw, 1.1rem) 0;
  display: grid;
  grid-template-rows: 1fr auto;
  align-items: start;
  gap: var(--spacing-2);
  position: relative;
  max-height: var(--project-accordion-closed-max);
  overflow: hidden;
  transition: max-height 0.35s ease;
}

.project-modal__accordion.is-open {
  max-height: var(--project-accordion-open-max);
}

.project-modal__description {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: var(--project-accordion-lines);
  max-height: var(--project-accordion-description-max);
  overflow: hidden;
  position: relative;
  transition: max-height 0.35s ease;
}

.project-modal__description::after {
  content: none;
}

.project-modal__accordion.is-open .project-modal__description {
  max-height: var(--project-accordion-description-open-max);
  overflow: visible;
  -webkit-line-clamp: unset;
  display: block;
}

.project-modal__description p {
  font-size: clamp(1.08rem, 1.35vw, 1.24rem);
  line-height: 1.78;
  margin: 0;
}

.project-modal__description p + p {
  margin-top: var(--spacing-2);
}

.project-modal__accordion-toggle {
  border: none;
  background: transparent;
  color: var(--fg);
  letter-spacing: 0.01em;
  text-transform: none;
  cursor: pointer;
  transition: color 0.2s ease;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: clamp(1rem, 1.1vw, 1.08rem);
  text-decoration: underline;
  padding: 0;
  vertical-align: baseline;
  justify-self: start;
  align-self: start;
  text-align: left;
}

.project-modal__accordion-toggle:hover,
.project-modal__accordion-toggle:focus-visible {
  color: rgba(255, 255, 255, 0.8);
}

.project-modal__gallery {
  display: grid;
  gap: var(--spacing-3);
  margin-top: clamp(1.4rem, 2.4vw, 2rem);
}

.project-modal__gallery img {
  width: 100%;
  display: block;
  border: none;
  border-radius: 0;
  object-fit: cover;
  box-shadow: none;
}

.project-modal__close {
  position: fixed;
  top: clamp(1.25rem, 2vw, 1.75rem);
  right: clamp(1.25rem, 2vw, 1.75rem);
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.02)),
    radial-gradient(120% 120% at 20% 20%, rgba(70, 132, 104, 0.28), transparent 55%),
    radial-gradient(140% 140% at 80% 10%, rgba(255, 255, 255, 0.18), transparent 60%);
  color: var(--fg);
  font-size: 1.1rem;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: transform 0.28s cubic-bezier(0.22, 0.61, 0.36, 1), background 0.28s cubic-bezier(0.22, 0.61, 0.36, 1), border-color 0.28s cubic-bezier(0.22, 0.61, 0.36, 1), box-shadow 0.28s cubic-bezier(0.22, 0.61, 0.36, 1);
  z-index: 2200;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.28);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  overflow: hidden;
  isolation: isolate;
}

.project-modal__close::after {
  content: '';
  position: absolute;
  inset: -45%;
  background: radial-gradient(140% 140% at var(--glow-x, 50%) var(--glow-y, 50%), rgba(70, 132, 104, 0.6), transparent 60%);
  opacity: 0.12;
  transition: opacity 0.25s ease;
  pointer-events: none;
  mix-blend-mode: screen;
}

.project-modal__close:hover,
.project-modal__close:focus-visible {
  transform: translateY(-2px) scale(1.06);
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.05)),
    radial-gradient(120% 120% at 20% 20%, rgba(70, 132, 104, 0.34), transparent 55%),
    radial-gradient(140% 140% at 80% 10%, rgba(255, 255, 255, 0.22), transparent 60%);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 18px 32px rgba(0, 0, 0, 0.38), inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.project-modal__close:hover::after,
.project-modal__close:focus-visible::after {
  opacity: 0.4;
}

@media (max-width: 720px) {
  :root {
    --project-thumb-height: 220px;
  }

  .project-modal {
    padding: var(--spacing-5);
  }

  .project-modal__content {
    max-height: calc(100vh - var(--spacing-5) * 2);
  }

  .project-modal__summary-row {
    gap: var(--spacing-3);
  }
}

@keyframes modal-rise {
  0% {
    transform: translateY(28px);
    opacity: 0;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}
/* Experience Timeline */
.experience-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--spacing-5);
}

.experience-heading {
  position: relative;
  text-align: center;
  width: 100%;
}

.experience-list {
  width: 100%;
  max-width: 800px;
  display: flex;
  flex-direction: column;
}

.experience-item {
  padding: var(--spacing-4) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
}

.experience-item:last-child {
  border-bottom: none;
}

.experience-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--spacing-3);
  flex-wrap: wrap;
}

.experience-role {
  font-size: var(--font-size-h3);
  font-weight: var(--font-weight-semibold);
  color: var(--fg);
}

.experience-meta {
  display: flex;
  align-items: center;
  gap: var(--spacing-3);
  font-size: var(--font-size-small);
  color: #d7dce3;
}

.experience-org {
  font-weight: var(--font-weight-semibold);
}

.experience-period {
  color: var(--muted);
}

.experience-description {
  margin-top: var(--spacing-3);
  font-size: var(--font-size-body);
  line-height: var(--line-height-normal);
  color: #fff;
}

/* Metrics */
.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--spacing-6);
  margin: var(--spacing-8) 0;
}

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

.metric-value {
  font-size: var(--font-size-h1);
  font-weight: var(--font-weight-bold);
  color: var(--accent);
  display: block;
  margin-bottom: var(--spacing-2);
}

.metric-label {
  font-size: var(--font-size-small);
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: var(--letter-spacing-kicker);
}

/* Education */
.education-list {
  list-style: none;
  max-width: 800px;
}

.education-item {
  padding: var(--spacing-4) 0;
  border-bottom: 1px solid var(--lines);
}

.education-item:last-child {
  border-bottom: none;
}

.education-title {
  font-size: var(--font-size-body);
  font-weight: var(--font-weight-semibold);
  color: var(--fg);
  margin-bottom: var(--spacing-1);
}

.education-org {
  font-size: var(--font-size-small);
  color: var(--muted);
}

/* CTA Section */
.cta-section {
  position: relative;
  text-align: center;
  padding: var(--spacing-10) 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  isolation: isolate;
}

.cta-section::before {
  content: '';
  position: absolute;
  inset: auto;
  left: 50%;
  bottom: -50%;
  width: clamp(520px, 70vw, 960px);
  aspect-ratio: 1;
  background: radial-gradient(circle at 45% 50%, rgba(72, 118, 94, 0.75), rgba(72, 118, 94, 0.46), transparent 68%);
  filter: blur(118px);
  opacity: 0.9;
  transform: translateX(-50%);
  pointer-events: none;
  z-index: 0;
  animation: float-orb-bottom 12s ease-in-out infinite alternate;
}

.cta-section .container {
  position: relative;
  z-index: 1;
}

.cta-heading {
  font-size: var(--font-size-h2);
  font-weight: var(--font-weight-bold);
  text-transform: uppercase;
  letter-spacing: var(--letter-spacing-kicker);
  margin-bottom: var(--spacing-8);
  color: #ddeddd;
}

/*.cta-heading::after {
  content: ".";
}*/

.cta-text {
  font-size: var(--font-size-body);
  color: var(--muted);
  margin-bottom: var(--spacing-6);
}

.cta-links {
  display: flex;
  gap: var(--spacing-4);
  justify-content: center;
  flex-wrap: wrap;
}

/* Buttons */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-2);
  padding: 0.78rem 1.5rem;
  color: #FFFFFF;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02)),
              radial-gradient(140% 160% at 18% 40%, rgba(39, 65, 51, 0.26), transparent 55%),
              radial-gradient(140% 160% at 80% 18%, rgba(255, 255, 255, 0.18), transparent 60%);
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--radius-pill);
  box-shadow: 0 16px 34px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(14px) saturate(150%);
  -webkit-backdrop-filter: blur(14px) saturate(150%);
  font-size: var(--font-size-small);
  font-weight: var(--font-weight-semibold);
  text-transform: uppercase;
  letter-spacing: var(--letter-spacing-kicker);
  cursor: pointer;
  transition:
    transform 0.25s ease,
    opacity 0.2s ease,
    box-shadow 0.35s ease,
    background 0.35s ease,
    border-color 0.35s ease;
  text-decoration: none;
  overflow: hidden;
  isolation: isolate;
}

.btn:hover {
  transform: translateY(-2px) scale(1.01);
  opacity: 1;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.14);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.03)),
              radial-gradient(150% 170% at 22% 36%, rgba(70, 132, 104, 0.32), transparent 52%),
              radial-gradient(140% 160% at 82% 16%, rgba(255, 255, 255, 0.2), transparent 60%);
  border-color: rgba(255, 255, 255, 0.18);
}

.cta-links .btn {
  overflow: hidden;
}

.cta-links .btn::after {
  content: '';
  position: absolute;
  inset: -45%;
  background: radial-gradient(140% 140% at var(--glow-x, 50%) var(--glow-y, 50%), rgba(70, 132, 104, 0.6), transparent 60%);
  opacity: 0.12;
  transition: opacity 0.25s ease;
  pointer-events: none;
  mix-blend-mode: screen;
}

.cta-links .btn:hover,
.cta-links .btn:focus-visible {
  transform: translateY(-2px) scale(1.06);
  background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0.05)),
    radial-gradient(120% 120% at 20% 20%, rgba(70, 132, 104, 0.34), transparent 55%),
    radial-gradient(140% 140% at 80% 10%, rgba(255, 255, 255, 0.22), transparent 60%);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 18px 32px rgba(0, 0, 0, 0.38), inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.cta-links .btn:hover::after,
.cta-links .btn:focus-visible::after {
  opacity: 0.4;
}

.btn-arrow {
  display: inline-block;
  width: 0.5rem;
  height: 0.5rem;
  border-top: 2px solid currentColor;
  border-right: 2px solid currentColor;
  transform: rotate(45deg);
  margin-left: var(--spacing-1);
}

/* Contact */
.contact-content {
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
}

.contact-text {
  font-size: var(--font-size-body);
  color: var(--muted);
  margin-bottom: var(--spacing-6);
}

.contact-email {
  font-size: var(--font-size-h3);
  font-weight: var(--font-weight-semibold);
  color: var(--accent);
  text-decoration: none;
}

.contact-email:hover {
  opacity: 0.8;
}

/* Responsive Design */
  @media (max-width: 960px) {
  .nav-container {
    padding: var(--spacing-2) calc(var(--nav-gap) * 0.75);
    justify-content: center;
  }

  .nav-links {
    gap: calc(var(--spacing-6) - 0.25rem);
    font-size: 0.88rem;
  }
  
  .hero-image {
    width: auto;
    height: 45vh;
    max-height: 350px;
    opacity: 0.75;
  }
  
  .scroll-text {
    font-size: clamp(3rem, 12vw, 8rem);
  }
  
  .work-grid {
    grid-template-columns: 1fr;
  }

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

    .experience-section {
      gap: var(--spacing-6);
    }

    .experience-meta {
      justify-content: flex-start;
    }
  }

@media (max-width: 860px) {
  body {
    padding-top: 0;
  }

  .nav-cta--outside {
    display: none;
  }

  .desktop-nav {
    display: none;
  }

  .mobile-menu {
    display: flex;
  }

  .nav {
    position: static;
    padding-top: var(--spacing-4);
  }
  
  .hero-image {
    width: auto;
    height: 40vh;
    max-height: 300px;
    opacity: 0.75;
  }
  
  .scroll-text {
    font-size: clamp(2.5rem, 10vw, 6rem);
  }

  .hero-text-container {
    padding: var(--spacing-4) 0;
  }

  .hero-name {
    font-size: clamp(2.5rem, 12vw, 5rem);
  }

  .hero-name-scroll {
    transform: translateY(0.35rem);
    margin-bottom: var(--spacing-3);
  }

  .skills-strip-scroll {
    margin-top: 0;
    padding-top: var(--spacing-2);
  }

  .skills-strip {
    font-size: 0.85rem;
  }
  
  .section {
    padding: var(--spacing-7) 0;
  }
  
  .metrics-grid {
    grid-template-columns: 1fr;
    gap: var(--spacing-4);
  }

  .experience-header {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--spacing-2);
  }

  .experience-meta {
    justify-content: flex-start;
  }

  .work-desktop-section {
    display: none;
  }

  .work-mobile-section {
    display: block;
  }

  .cta-links {
    flex-direction: column;
    align-items: center;
  }

  .project-modal__content {
    padding-top: calc(var(--spacing-6) + 1.5rem);
  }

  .project-modal__header {
    padding-top: var(--spacing-1);
  }
}

/* Utility Classes */
.text-center {
  text-align: center;
}

.mb-0 {
  margin-bottom: 0;
}

.mt-0 {
  margin-top: 0;
}

