/* ============================================
   SELF-HOSTED FONTS (no external dependencies)
   ============================================ */

/* Instrument Serif - Regular */
@font-face {
  font-family: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/instrument-serif/InstrumentSerif-Regular-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/instrument-serif/InstrumentSerif-Regular-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* Instrument Serif - Italic */
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/instrument-serif/InstrumentSerif-Italic-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Instrument Serif';
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/instrument-serif/InstrumentSerif-Italic-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* Inter - Latin */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/inter/Inter-Variable-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Inter - Latin Extended */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/inter/Inter-Variable-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Inter - Greek */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/inter/Inter-Variable-greek.woff2') format('woff2');
  unicode-range: U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
}
/* Inter - Greek Extended */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/inter/Inter-Variable-greek-ext.woff2') format('woff2');
  unicode-range: U+1F00-1FFF;
}

/* ============================================
   TOKENS — THEMED
   ============================================ */
:root {
  /* shared */
  --accent: #ff5b1f;
  --accent-2: #ffb86b;
  --font-display: "Instrument Serif", Georgia, serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;

  --step--1: clamp(0.83rem, 0.81rem + 0.11vw, 0.89rem);
  --step-0: clamp(1rem, 0.95rem + 0.22vw, 1.13rem);
  --step-1: clamp(1.2rem, 1.12rem + 0.4vw, 1.42rem);
  --step-2: clamp(1.44rem, 1.31rem + 0.66vw, 1.8rem);
  --step-3: clamp(1.73rem, 1.53rem + 1vw, 2.27rem);
  --step-4: clamp(2.07rem, 1.78rem + 1.47vw, 2.87rem);
  --step-5: clamp(2.49rem, 2.06rem + 2.12vw, 3.62rem);
  --step-6: clamp(2.99rem, 2.38rem + 3.03vw, 4.58rem);
  --step-7: clamp(3.58rem, 2.73rem + 4.27vw, 5.78rem);
  --step-8: clamp(4.3rem, 3.13rem + 5.87vw, 7.3rem);

  --gutter: clamp(1.25rem, 4vw, 3rem);
  --section-y: clamp(5rem, 10vw, 9rem);
  --max-w: 1400px;
  --radius: 16px;
  --radius-lg: 24px;
}

[data-theme="dark"] {
  --bg: #0a0a0b;
  --bg-elev: #131316;
  --bg-elev-2: #1a1a1f;
  --fg: #f4f3ef;
  --fg-soft: #b8b5ad;
  --fg-mute: #75726b;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.18);
  --grain: rgba(255,255,255,0.02);
}
[data-theme="light"] {
  --bg: #f6f3ec;
  --bg-elev: #ffffff;
  --bg-elev-2: #ede8dc;
  --fg: #14130f;
  --fg-soft: #4a4742;
  --fg-mute: #8a857d;
  --line: rgba(20, 19, 15, 0.10);
  --line-strong: rgba(20, 19, 15, 0.22);
  --grain: rgba(0,0,0,0.015);
}

/* ============================================
   RESET
   ============================================ */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.6;
  color: var(--fg);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  transition: background 0.4s ease, color 0.4s ease;
  overflow-x: hidden;
}
img, svg, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; background: none; border: none; color: inherit; padding: 0; }
::selection { background: var(--accent); color: #fff; }

/* Mobile robustness: prevent long words from breaking layouts on narrow screens */
h1, h2, h3, h4 {
  overflow-wrap: break-word;
  word-wrap: break-word;
  hyphens: auto;
}
.stat__label, .stat__value, .project__cat, .service__tag, .filter, .skill__name {
  overflow-wrap: break-word;
  word-wrap: break-word;
}

/* ============================================
   LAYOUT
   ============================================ */
.wrap { width: 100%; max-width: var(--max-w); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section-y); position: relative; }

/* ============================================
   NAV
   ============================================ */
.nav {
  position: fixed;
  top: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  width: calc(100% - 2rem);
  max-width: 920px;
  background: color-mix(in srgb, var(--bg-elev) 75%, transparent);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.55rem 0.55rem 0.55rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
.nav__brand {
  font-family: var(--font-display);
  font-size: var(--step-1);
  letter-spacing: -0.02em;
  font-style: italic;
  white-space: nowrap;
}
.nav__brand span { color: var(--accent); }
.nav__links {
  display: flex;
  gap: 1.4rem;
  list-style: none;
  padding: 0;
  font-size: var(--step--1);
}
.nav__link {
  color: var(--fg-soft);
  transition: color 0.2s ease;
  position: relative;
}
.nav__link:hover { color: var(--fg); }
.nav__right { display: flex; gap: 0.45rem; align-items: center; }

/* Round button shared style */
.nav__round-btn {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--bg-elev-2);
  border: 1px solid var(--line);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, border-color 0.2s, transform 0.3s;
  flex-shrink: 0;
}
.nav__round-btn:hover { border-color: var(--line-strong); }

.theme-toggle:hover { transform: rotate(45deg); }
.theme-toggle svg { width: 18px; height: 18px; stroke: var(--fg); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
[data-theme="light"] .theme-toggle .icon-sun { display: none; }
[data-theme="light"] .theme-toggle .icon-moon { display: block; }

/* Language switcher */
.lang {
  position: relative;
}
.lang__current {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0 0.55rem;
  height: 38px;
  border-radius: 999px;
  background: var(--bg-elev-2);
  border: 1px solid var(--line);
  font-size: var(--step--1);
  font-weight: 500;
  color: var(--fg);
  transition: background 0.2s, border-color 0.2s;
}
.lang__current:hover { border-color: var(--line-strong); }
.lang__flag {
  width: 18px;
  height: 13px;
  border-radius: 2px;
  overflow: hidden;
  display: inline-block;
  flex-shrink: 0;
}
.lang__chevron {
  width: 10px; height: 10px;
  stroke: var(--fg-mute);
  fill: none;
  stroke-width: 2;
  transition: transform 0.3s;
}
.lang.is-open .lang__chevron { transform: rotate(180deg); }
.lang__menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 140px;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.35rem;
  box-shadow: 0 12px 32px -8px rgba(0,0,0,0.3);
  opacity: 0;
  transform: translateY(-8px);
  visibility: hidden;
  transition: opacity 0.2s, transform 0.2s, visibility 0s 0.2s;
  z-index: 110;
}
.lang.is-open .lang__menu {
  opacity: 1;
  transform: translateY(0);
  visibility: visible;
  transition: opacity 0.2s, transform 0.2s, visibility 0s;
}
.lang__option {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 0.55rem;
  padding: 0.55rem 0.7rem;
  border-radius: 8px;
  font-size: var(--step--1);
  color: var(--fg);
  text-align: left;
  transition: background 0.15s;
}
.lang__option:hover, .lang__option.is-active { background: var(--bg-elev-2); }
.lang__option.is-active { font-weight: 600; }

/* CTA button */
.nav__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: var(--step--1);
  font-weight: 500;
  padding: 0.6rem 1.1rem;
  background: var(--accent);
  color: #fff;
  border-radius: 999px;
  transition: background 0.2s, transform 0.2s;
  white-space: nowrap;
}
.nav__cta:hover { background: #ff7440; transform: translateY(-1px); }

/* Hamburger — hidden on desktop */
.nav__burger {
  display: none;
  flex-direction: column;
  gap: 4px;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--bg-elev-2);
  border: 1px solid var(--line);
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.nav__burger span {
  display: block;
  width: 16px;
  height: 1.5px;
  background: var(--fg);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.2s;
}
.nav__burger.is-open span:nth-child(1) { transform: translateY(5.5px) rotate(45deg); }
.nav__burger.is-open span:nth-child(2) { opacity: 0; }
.nav__burger.is-open span:nth-child(3) { transform: translateY(-5.5px) rotate(-45deg); }

/* Mobile overlay menu */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(1.5rem, 4vh, 2.5rem);
  padding: 6rem 2rem 3rem;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-100%);
  transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), visibility 0s 0.4s;
}
.mobile-menu.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  transition: opacity 0.4s ease, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), visibility 0s;
}
.mobile-menu__links {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: clamp(1rem, 3vh, 1.8rem);
  text-align: center;
}
.mobile-menu__link {
  font-family: var(--font-display);
  font-size: clamp(2rem, 8vw, 3.5rem);
  letter-spacing: -0.02em;
  font-weight: 400;
  color: var(--fg);
  transition: color 0.2s;
  display: inline-block;
}
.mobile-menu__link:hover, .mobile-menu__link:active { color: var(--accent); }
.mobile-menu__link em { font-style: italic; color: var(--accent); }
.mobile-menu__cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: var(--step-0);
  font-weight: 500;
  padding: 0.95rem 1.7rem;
  background: var(--accent);
  color: #fff;
  border-radius: 999px;
  margin-top: 1rem;
}
/* Prevent body scroll when menu open */
body.menu-open { overflow: hidden; }

/* Responsive breakpoints for nav */
@media (max-width: 860px) {
  .nav__links { display: none; }
  .nav__cta { display: none; }
  .nav__burger { display: inline-flex; }
}
@media (max-width: 420px) {
  .nav {
    padding: 0.5rem 0.5rem 0.5rem 1rem;
    width: calc(100% - 1rem);
  }
  .nav__brand { font-size: var(--step-0); }
  .lang__current { padding: 0 0.45rem; }
  .nav__right { gap: 0.35rem; }
}

/* ============================================
   HERO
   ============================================ */
.hero {
  padding-top: clamp(7rem, 14vw, 10rem);
  padding-bottom: clamp(3rem, 6vw, 5rem);
  position: relative;
  overflow: hidden;
}
.hero__grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse at 50% 30%, black 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 30%, black 30%, transparent 75%);
  pointer-events: none;
}
/* Soft drifting gradient blob — light motion behind hero */
.hero__blob {
  position: absolute;
  width: clamp(400px, 60vw, 720px);
  height: clamp(400px, 60vw, 720px);
  top: 20%;
  left: 60%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle at 40% 40%,
    color-mix(in srgb, var(--accent) 35%, transparent) 0%,
    color-mix(in srgb, var(--accent) 12%, transparent) 35%,
    transparent 70%);
  filter: blur(60px);
  pointer-events: none;
  animation: blobDrift 18s ease-in-out infinite alternate;
  z-index: 0;
}
@keyframes blobDrift {
  0%   { transform: translate(-50%, -50%) scale(1); }
  50%  { transform: translate(-40%, -55%) scale(1.08); }
  100% { transform: translate(-55%, -45%) scale(0.95); }
}
/* Word-by-word headline reveal */
.hero__headline .word {
  display: inline-block;
  opacity: 0;
  transform: translateY(0.5em);
  filter: blur(8px);
  animation: wordIn 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.hero__headline .word--space { width: 0.3em; }
@keyframes wordIn {
  to { opacity: 1; transform: translateY(0); filter: blur(0); }
}
.hero__inner { position: relative; z-index: 1; }
.hero__pill {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: var(--step--1);
  padding: 0.5rem 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: color-mix(in srgb, var(--bg-elev) 60%, transparent);
  margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
  font-weight: 500;
}
.hero__dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 0 4px rgba(74, 222, 128, 0.18);
  animation: pulse 2.5s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.55; }
}
.hero__headline {
  font-family: var(--font-display);
  font-size: var(--step-8);
  line-height: 0.92;
  letter-spacing: -0.04em;
  font-weight: 400;
  margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
  max-width: 16ch;
}
.hero__headline em {
  font-style: italic;
  color: var(--accent);
}
.hero__sub {
  font-size: var(--step-1);
  line-height: 1.5;
  color: var(--fg-soft);
  max-width: 56ch;
  margin-bottom: clamp(2rem, 4vw, 3rem);
}
.hero__actions { display: flex; gap: 1rem; flex-wrap: wrap; }
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1rem 1.7rem;
  border-radius: 999px;
  font-size: var(--step-0);
  font-weight: 500;
  transition: transform 0.2s, background 0.2s, color 0.2s, border-color 0.2s;
}
.btn--primary { background: var(--fg); color: var(--bg); }
.btn--primary:hover { background: var(--accent); color: #fff; transform: translateY(-2px); }
.btn--ghost { border: 1px solid var(--line-strong); }
.btn--ghost:hover { border-color: var(--fg); transform: translateY(-2px); }
.btn__arrow { display: inline-block; transition: transform 0.2s; }
.btn:hover .btn__arrow { transform: translateX(4px); }

/* Marquee row of services */
.marquee {
  margin-top: clamp(4rem, 8vw, 6rem);
  padding-block: 2rem;
  border-block: 1px solid var(--line);
  overflow: hidden;
  position: relative;
}
.marquee__track {
  display: flex;
  gap: 3rem;
  width: max-content;
  animation: marquee 40s linear infinite;
}
.marquee__item {
  font-family: var(--font-display);
  font-size: var(--step-4);
  font-style: italic;
  color: var(--fg-soft);
  display: inline-flex;
  align-items: center;
  gap: 3rem;
  white-space: nowrap;
}
.marquee__item::after {
  content: "✦";
  color: var(--accent);
  font-style: normal;
  font-size: 0.7em;
}
@keyframes marquee {
  to { transform: translateX(-50%); }
}

/* Stats */
.hero__stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(1.5rem, 3vw, 2.5rem);
  margin-top: clamp(3rem, 6vw, 5rem);
  padding-top: clamp(2rem, 4vw, 3rem);
  border-top: 1px solid var(--line);
}
@media (min-width: 720px) { .hero__stats { grid-template-columns: repeat(4, 1fr); } }
.stat__label {
  font-size: var(--step--1);
  color: var(--fg-mute);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: 0.5rem;
}
.stat__value {
  font-family: var(--font-display);
  font-size: var(--step-4);
  letter-spacing: -0.02em;
}
.stat__value em { font-style: italic; color: var(--accent); }

/* ============================================
   SERVICES
   ============================================ */
.services { background: var(--bg-elev); }
.section__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: clamp(3rem, 5vw, 4rem);
  flex-wrap: wrap;
}
.section__label {
  font-size: var(--step--1);
  color: var(--fg-mute);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
.section__label::before {
  content: "";
  width: 28px; height: 1px;
  background: var(--accent);
}
.section__title {
  font-family: var(--font-display);
  font-size: var(--step-6);
  line-height: 1;
  letter-spacing: -0.03em;
  margin-top: 0.8rem;
  max-width: 18ch;
}
.section__title em { font-style: italic; color: var(--accent); }
.section__desc {
  max-width: 38ch;
  color: var(--fg-soft);
  font-size: var(--step-0);
  line-height: 1.55;
}

.services__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
@media (min-width: 720px) { .services__grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .services__grid { grid-template-columns: repeat(3, 1fr); } }

.service {
  background: var(--bg-elev);
  padding: clamp(1.75rem, 3vw, 2.25rem);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  position: relative;
  transition: background 0.3s ease;
}
.service:hover { background: var(--bg-elev-2); }
.service__num {
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--step--1);
  color: var(--accent);
  font-weight: 400;
}
.service__icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  background: color-mix(in srgb, var(--accent) 15%, transparent);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 0.5rem;
}
.service__icon svg { width: 22px; height: 22px; stroke: var(--accent); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.service__title {
  font-family: var(--font-display);
  font-size: var(--step-3);
  letter-spacing: -0.02em;
  line-height: 1.1;
}
.service__desc {
  color: var(--fg-soft);
  font-size: var(--step-0);
  line-height: 1.55;
  flex-grow: 1;
}
.service__tag {
  display: inline-flex;
  font-size: var(--step--1);
  color: var(--fg-mute);
  padding-top: 0.5rem;
  border-top: 1px dashed var(--line);
  margin-top: auto;
  font-weight: 500;
}
.service__tag--new {
  color: var(--accent);
}
.service__tag--new::before {
  content: "✦";
  margin-right: 0.4rem;
}

/* ============================================
   PROJECTS
   ============================================ */
.projects__filters {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}
.filter {
  font-size: var(--step--1);
  padding: 0.5rem 1.1rem;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  color: var(--fg-soft);
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  font-weight: 500;
}
.filter:hover { color: var(--fg); border-color: var(--fg); }
.filter.is-active { background: var(--fg); color: var(--bg); border-color: var(--fg); }

.projects__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(1.25rem, 2.5vw, 2rem);
}
@media (min-width: 720px) { .projects__grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .projects__grid { grid-template-columns: repeat(3, 1fr); } }

.project {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-elev);
  border: 1px solid var(--line);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.3s;
  display: flex;
  flex-direction: column;
}
.project:hover { transform: translateY(-6px); border-color: var(--line-strong); }
.project__visual {
  aspect-ratio: 5 / 4;
  position: relative;
  overflow: hidden;
  background: var(--bg-elev-2);
}
.project__art {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.project:hover .project__art { transform: scale(1.05); }

.project__meta {
  padding: 1.25rem 1.5rem 1.5rem;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
}
.project__name {
  font-family: var(--font-display);
  font-size: var(--step-2);
  letter-spacing: -0.015em;
  line-height: 1.15;
  margin-bottom: 0.3rem;
}
.project__cat { font-size: var(--step--1); color: var(--fg-mute); }
.project__view {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--bg-elev-2);
  flex-shrink: 0;
  transition: background 0.2s, transform 0.2s;
}
.project:hover .project__view { background: var(--accent); transform: rotate(-45deg); }
.project__view svg { width: 14px; height: 14px; stroke: var(--fg); fill: none; stroke-width: 2; }
.project:hover .project__view svg { stroke: #fff; }

/* Abstract project artworks - removed (real images now used) */

/* ============================================
   ABOUT
   ============================================ */
.about { background: var(--bg-elev); }
.about__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(2.5rem, 5vw, 4rem);
  align-items: start;
}
@media (min-width: 900px) { .about__grid { grid-template-columns: 5fr 7fr; } }
.about__heading {
  font-family: var(--font-display);
  font-size: var(--step-5);
  line-height: 1.05;
  letter-spacing: -0.025em;
  font-weight: 400;
}
/* Only stick on desktop where two-column layout exists */
@media (min-width: 900px) {
  .about__heading {
    position: sticky;
    top: 7rem;
  }
}
.about__heading em { font-style: italic; color: var(--accent); }
.about__body {
  font-size: var(--step-1);
  line-height: 1.6;
  color: var(--fg-soft);
}
.about__body p + p { margin-top: 1.4rem; }
.about__body strong { color: var(--fg); font-weight: 500; }

.skills {
  margin-top: clamp(2.5rem, 5vw, 4rem);
  padding-top: clamp(2rem, 4vw, 3rem);
  border-top: 1px solid var(--line);
}
.skills__title {
  font-size: var(--step--1);
  color: var(--fg-mute);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: 1.5rem;
}
.skill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--line);
  font-size: var(--step-0);
}
.skill__name { color: var(--fg); font-weight: 500; }
.skill__bar { flex: 1; max-width: 200px; height: 4px; background: var(--bg-elev-2); border-radius: 2px; overflow: hidden; }
.skill__fill { height: 100%; background: var(--accent); border-radius: 2px; transition: width 1.2s cubic-bezier(0.16, 1, 0.3, 1); width: 0; }
.skill__pct { font-family: var(--font-display); font-style: italic; color: var(--fg-mute); min-width: 3ch; text-align: right; }

/* ============================================
   PROCESS
   ============================================ */
.process__steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
@media (min-width: 720px) { .process__steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .process__steps { grid-template-columns: repeat(4, 1fr); } }
.step {
  background: var(--bg);
  padding: clamp(1.75rem, 3vw, 2.25rem);
  transition: background 0.3s;
}
.step:hover { background: var(--bg-elev); }
.step__num {
  font-family: var(--font-display);
  font-size: var(--step-6);
  font-style: italic;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 1rem;
}
.step__title {
  font-family: var(--font-display);
  font-size: var(--step-2);
  letter-spacing: -0.015em;
  margin-bottom: 0.6rem;
  line-height: 1.1;
}
.step__desc { color: var(--fg-soft); font-size: var(--step--1); line-height: 1.55; }

/* ============================================
   FEATURED WORK (deep-dive case studies)
   ============================================ */
.featured { background: var(--bg-elev); }
.featured__list {
  display: flex;
  flex-direction: column;
  gap: clamp(3rem, 7vw, 6rem);
}
.featured__item {
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(1.5rem, 3vw, 2.5rem);
  align-items: center;
}
@media (min-width: 900px) {
  .featured__item { grid-template-columns: 1.05fr 1fr; }
  /* Alternate layout — second item has image on the right */
  .featured__item:nth-child(even) .featured__visual { order: 2; }
}
.featured__visual {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-elev-2);
  border: 1px solid var(--line);
  aspect-ratio: 5 / 4;
}
.featured__visual img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.featured__item:hover .featured__visual img { transform: scale(1.03); }

.featured__num {
  font-family: var(--font-display);
  font-style: italic;
  font-size: var(--step--1);
  color: var(--accent);
  font-weight: 400;
  letter-spacing: 0.04em;
  margin-bottom: 0.6rem;
}
.featured__title {
  font-family: var(--font-display);
  font-size: var(--step-5);
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin-bottom: 1rem;
  font-weight: 400;
}
.featured__title em { font-style: italic; color: var(--accent); }
.featured__desc {
  color: var(--fg-soft);
  font-size: var(--step-0);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}
.featured__desc strong { color: var(--fg); font-weight: 500; }
.featured__features {
  list-style: none;
  padding: 0;
  margin: 0 0 1.5rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem 1rem;
}
.featured__features li {
  font-size: var(--step--1);
  color: var(--fg-soft);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.featured__features li::before {
  content: "";
  flex-shrink: 0;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--accent);
}
.featured__stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 1.5rem;
}
.featured__stack span {
  font-size: var(--step--1);
  padding: 0.3rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--fg-soft);
  background: var(--bg);
}
.featured__link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: var(--step-0);
  font-weight: 500;
  color: var(--accent);
  transition: gap 0.2s;
}
.featured__link:hover { gap: 0.85rem; }
.featured__link::after {
  content: "→";
  transition: transform 0.2s;
}

/* ============================================
   CTA
   ============================================ */
.cta {
  background: var(--bg-elev);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 100%, color-mix(in srgb, var(--accent) 30%, transparent), transparent 60%);
  pointer-events: none;
}
.cta__inner { position: relative; z-index: 1; }
.cta__intro {
  font-size: var(--step--1);
  color: var(--fg-mute);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 500;
  margin-bottom: clamp(1.5rem, 3vw, 2rem);
}
.cta__title {
  font-family: var(--font-display);
  font-size: var(--step-8);
  line-height: 0.95;
  letter-spacing: -0.035em;
  font-weight: 400;
  margin-bottom: clamp(2rem, 4vw, 3rem);
  max-width: 14ch;
  margin-inline: auto;
}
.cta__title em { font-style: italic; color: var(--accent); }
.cta__email {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-size: var(--step-3);
  font-style: italic;
  color: var(--accent);
  border-bottom: 1px solid var(--accent);
  padding-bottom: 0.3rem;
  transition: opacity 0.2s;
}
.cta__email:hover { opacity: 0.75; }
.cta__channels {
  display: flex;
  justify-content: center;
  gap: clamp(1.5rem, 3vw, 2.5rem);
  margin-top: clamp(2.5rem, 5vw, 4rem);
  font-size: var(--step--1);
  color: var(--fg-mute);
  flex-wrap: wrap;
}
.cta__channels a { transition: color 0.2s; }
.cta__channels a:hover { color: var(--fg); }

/* ============================================
   FOOTER
   ============================================ */
.footer {
  padding-block: 2.5rem;
  border-top: 1px solid var(--line);
  background: var(--bg);
}
.footer__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: var(--step--1);
  color: var(--fg-mute);
}

/* ============================================
   REVEAL
   ============================================ */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1), transform 0.9s cubic-bezier(0.16, 1, 0.3, 1); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .marquee__track { animation: none; }
  .hero__blob { animation: none; opacity: 0.6; }
  .hero__headline .word { opacity: 1; transform: none; filter: none; animation: none; }
}