/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #0a0a0a;
  --surface: #111111;
  --surface2: #1a1a1a;
  --text: #f0f0f0;
  --muted: #666;
  --muted2: #444;
  --accent: #ff6b2b;
  --border: rgba(255,255,255,0.07);
  --font-main: 'Jost', sans-serif;
  --font-mono: 'Space Mono', monospace;
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-main);
  line-height: 1.6;
  overflow-x: hidden;
}

::selection { background: var(--accent); color: #000; }
a { text-decoration: none; color: inherit; }
img { display: block; width: 100%; }

.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 2.5rem;
}

/* ===== NAV ===== */
#nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 2rem;
  background: transparent;
  border-bottom: none;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

#nav.scrolled { background: transparent; border-bottom: none; }

#nav.nav-hidden {
  opacity: 0;
  transform: translateY(-130%);
  pointer-events: none;
}

.nav-logo {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-transform: lowercase;
  display: flex;
  align-items: center;
  gap: 0.45rem;
  background: rgba(15,15,15,0.72);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 9999px;
  padding: 0.5rem 1.1rem 0.5rem 0.55rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.07);
}

.nav-logo-mark {
  height: 28px;
  width: auto;
  display: block;
  filter: invert(1);
  mix-blend-mode: screen;
}

.dot { color: var(--accent); font-weight: 700; }

.nav-links {
  position: fixed;
  top: 1.25rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 101;
  list-style: none;
  display: flex;
  gap: 0;
  background: rgba(15,15,15,0.72);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 9999px;
  padding: 0.35rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.07);
  transition: transform 0.35s ease, opacity 0.35s ease;
}

.nav-links.nav-hidden {
  opacity: 0;
  transform: translateX(-50%) translateY(-200%);
  pointer-events: none;
}

.nav-links a {
  display: block;
  padding: 0.5rem 1.25rem;
  border-radius: 9999px;
  font-size: 0.8rem;
  font-weight: 500;
  color: rgba(255,255,255,0.55);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: color 0.2s, background 0.2s;
}

.nav-links a:hover {
  color: #fff;
  background: rgba(255,255,255,0.1);
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.45rem 0.6rem;
}

.hamburger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--text);
  transition: all 0.3s;
}

.hamburger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99;
  background: var(--bg);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2.5rem;
}

.mobile-menu.open { display: flex; }

.mobile-link {
  font-size: 2.8rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  transition: color 0.2s;
}

.mobile-link:hover { color: var(--accent); }

/* ===== HERO ===== */
#hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 8rem 3rem 3rem;
}

.hero-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
}

.hero-location {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: 0.06em;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4ade80;
  box-shadow: 0 0 8px #4ade80;
  animation: pulse 2.5s ease-in-out infinite;
}

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

.hero-content { flex: 1; display: flex; flex-direction: column; justify-content: center; padding: 2rem 0; }

.hero-title {
  font-size: clamp(3.5rem, 9vw, 8rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1;
  margin-bottom: 1.5rem;
}

.hero-statement {
  font-size: clamp(1.4rem, 3.5vw, 2.8rem);
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--muted);
  margin-bottom: 1.8rem;
}

.hero-statement em {
  font-style: italic;
  color: var(--text);
  font-weight: 400;
}

.hero-sub {
  font-size: 1rem;
  color: var(--muted);
  max-width: 460px;
  line-height: 1.75;
  margin-bottom: 2.5rem;
}

.hero-cta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero-bottom {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.hero-degree, .hero-scroll-hint {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

/* ===== BUTTONS ===== */
.btn-primary {
  display: inline-block;
  background: var(--accent);
  color: #000;
  font-family: var(--font-main);
  font-weight: 700;
  font-size: 0.88rem;
  padding: 0.9rem 2rem;
  border-radius: 9999px;
  letter-spacing: 0.02em;
  box-shadow: 0 4px 20px rgba(255,107,43,0.3), inset 0 1px 0 rgba(255,255,255,0.25);
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 32px rgba(255,107,43,0.45), inset 0 1px 0 rgba(255,255,255,0.25);
}

.btn-ghost {
  display: inline-block;
  border: 1px solid rgba(255,255,255,0.12);
  color: var(--muted);
  font-family: var(--font-main);
  font-weight: 500;
  font-size: 0.88rem;
  padding: 0.9rem 2rem;
  border-radius: 9999px;
  background: rgba(255,255,255,0.04);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.07);
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.btn-ghost:hover {
  border-color: rgba(255,255,255,0.28);
  color: var(--text);
  background: rgba(255,255,255,0.08);
}

/* ===== MARQUEE ===== */
.marquee-wrap {
  overflow: hidden;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  padding: 1rem 0;
}

.marquee-track {
  display: flex;
  gap: 2.5rem;
  align-items: center;
  white-space: nowrap;
  animation: marquee 28s linear infinite;
  width: max-content;
}

.marquee-track span {
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.marquee-dot {
  color: var(--accent) !important;
  font-size: 0.6rem !important;
}

@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

.marquee-track.paused { animation-play-state: paused; }

/* ===== SECTION SHARED ===== */
.section-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 1.2rem;
}

.section-title {
  font-size: clamp(2.2rem, 4.5vw, 3.6rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.08;
}

.section-title em {
  font-style: italic;
  font-weight: 300;
  color: var(--muted);
}

/* ===== ABOUT ===== */
#about {
  padding: 9rem 0;
  border-bottom: 1px solid var(--border);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 7rem;
  align-items: start;
}

.about-left { position: sticky; top: 8rem; }

.about-right p {
  color: var(--muted);
  line-height: 1.85;
  margin-bottom: 1.4rem;
  font-size: 1.05rem;
}

/* ===== ABOUT PHOTO ===== */
.about-photo {
  margin-top: 2.5rem;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  position: relative;
  background: var(--surface2);
  border: 1px solid var(--border);
}

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

.about-photo-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px dashed rgba(255,255,255,0.1);
  border-radius: 16px;
}

.about-photo-placeholder span {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted2);
}

.skills-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.skill-item {
  display: inline-flex;
  align-items: center;
  font-size: 0.8rem;
  color: var(--text);
  font-weight: 400;
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: 9999px;
  padding: 0.4rem 1rem;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06);
}

.skill-dot { display: none; }

/* ===== WORK ===== */
#work {
  padding: 9rem 0;
  border-bottom: 1px solid var(--border);
}

.work-header { margin-bottom: 3.5rem; }

.work-header-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}

.filter-bar {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.filter-btn {
  background: none;
  border: 1px solid var(--border);
  color: var(--muted);
  font-family: var(--font-main);
  font-size: 0.8rem;
  font-weight: 500;
  padding: 0.45rem 1rem;
  border-radius: 100px;
  cursor: pointer;
  transition: all 0.2s;
  letter-spacing: 0.03em;
}

.filter-btn:hover, .filter-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #000;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.project-card {
  background: rgba(255,255,255,0.04);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(0,0,0,0.35), inset 0 1px 0 rgba(255,255,255,0.06);
  transition: border-color 0.3s, transform 0.3s, box-shadow 0.3s;
}

.project-card:hover {
  border-color: rgba(255,255,255,0.2);
  transform: translateY(-6px);
  box-shadow: 0 20px 52px rgba(0,0,0,0.45), inset 0 1px 0 rgba(255,255,255,0.1);
}

.project-card.hidden { display: none; }

.project-img {
  height: 260px;
  position: relative;
  overflow: hidden;
  background: var(--surface);
}

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

.project-img-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 1.2rem;
}

.project-num {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.06em;
}

.project-info { padding: 1.6rem; }

.project-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 0.9rem;
}

.project-meta {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.project-tag {
  font-size: 0.65rem;
  font-weight: 600;
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  background: rgba(255,255,255,0.06);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.09);
  padding: 0.25rem 0.65rem;
  border-radius: 9999px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.06);
}

.project-arrow {
  font-size: 1.1rem;
  color: var(--muted2);
  transition: color 0.2s, transform 0.2s;
  flex-shrink: 0;
  line-height: 1;
}

.project-card:hover .project-arrow {
  color: var(--accent);
  transform: translate(2px, -2px);
}

.project-title {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 0.6rem;
  line-height: 1.2;
}

.project-desc {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.7;
}

/* ===== APPROACH ===== */
#approach {
  padding: 9rem 0;
  border-bottom: 1px solid var(--border);
}

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

.approach-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.approach-item {
  padding: 3rem;
  border-radius: 20px;
  background: rgba(255,255,255,0.04);
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  border: 1px solid rgba(255,255,255,0.09);
  box-shadow: 0 4px 24px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.06);
  transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
}

.approach-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 44px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.16);
}

.approach-num {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--accent);
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 1.2rem;
}

.approach-item h3 {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.8rem;
}

.approach-item p {
  font-size: 0.92rem;
  color: var(--muted);
  line-height: 1.8;
}

/* ===== CONTACT ===== */
#contact {
  padding: 10rem 0 8rem;
}

.contact-big {
  font-size: clamp(3rem, 8vw, 7rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.0;
  margin: 1.5rem 0 3.5rem;
}

.contact-big em {
  font-style: italic;
  font-weight: 300;
  color: var(--accent);
}

.contact-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 3rem;
  flex-wrap: wrap;
  padding-bottom: 3.5rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2.5rem;
}

.contact-sub {
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.8;
  max-width: 480px;
}

.contact-btn { font-size: 0.95rem; padding: 1rem 2.5rem; white-space: nowrap; }

.social-links {
  display: flex;
  gap: 2.5rem;
  flex-wrap: wrap;
}

.social-link {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--muted);
  letter-spacing: 0.04em;
  transition: color 0.2s;
}

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

/* ===== FOOTER ===== */
#footer {
  padding: 2rem 0;
  border-top: 1px solid var(--border);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-logo {
  font-size: 1rem;
  font-weight: 700;
  text-transform: lowercase;
}

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

/* ===== REVEAL ===== */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1), transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== MOTION ===== */
@keyframes siteLoad {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
body { animation: siteLoad 0.7s cubic-bezier(0.16, 1, 0.3, 1) both; }

/* Hero entrance stagger */
.hero-top.reveal      { transition-delay: 0.05s; }
.hero-title.reveal    { transition-delay: 0.2s; }
.hero-statement.reveal{ transition-delay: 0.35s; }
.hero-sub.reveal      { transition-delay: 0.5s; }
.hero-cta.reveal      { transition-delay: 0.65s; }
.hero-bottom.reveal   { transition-delay: 0.8s; }

/* Card image zoom on hover */
.project-img img { transition: transform 0.65s cubic-bezier(0.16, 1, 0.3, 1); }
.project-card:hover .project-img img { transform: scale(1.06); }

/* Social link lift */
.social-link { display: inline-block; transition: color 0.2s, transform 0.25s cubic-bezier(0.16, 1, 0.3, 1); }
.social-link:hover { transform: translateY(-3px); }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 3.5rem; }
  .about-left { position: static; }
  .projects-grid { grid-template-columns: 1fr; }
  .approach-grid { grid-template-columns: 1fr; }
  .work-header-row { flex-direction: column; align-items: flex-start; }
}


/* ===== LOADER ===== */
#loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: #0a0a0a;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 1s cubic-bezier(0.76, 0, 0.24, 1);
}

#loader.done {
  transform: translateY(-100%);
  pointer-events: none;
}

.loader-wordmark {
  font-family: var(--font-main);
  font-size: clamp(2rem, 6vw, 4.5rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  color: #f0f0f0;
  text-transform: lowercase;
  animation: loaderIn 0.7s cubic-bezier(0.16, 1, 0.3, 1) both;
}

@keyframes loaderIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ===== PROJECT SLIDES ===== */
.slides-wrap {
  width: 100%;
}

.project-slide {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
  padding: 4rem;
}

.project-slide.hidden { display: none; }

.slide-bg {
  position: absolute;
  inset: 0;
  transition: transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.slide-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.slide-bg-gradient {
  position: absolute;
  inset: 0;
}

.project-slide:hover .slide-bg {
  transform: scale(1.03);
}

.slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.82) 0%, rgba(0,0,0,0.25) 50%, rgba(0,0,0,0.1) 100%);
  pointer-events: none;
}

.slide-content {
  position: relative;
  z-index: 2;
  max-width: 700px;
}

.slide-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.2rem;
  gap: 1rem;
}

.slide-tags {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.slide-num {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: rgba(255,255,255,0.35);
  letter-spacing: 0.1em;
  flex-shrink: 0;
}

.slide-title {
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin-bottom: 0.9rem;
  color: #fff;
}

.slide-desc {
  font-size: 0.95rem;
  color: rgba(255,255,255,0.6);
  line-height: 1.75;
  max-width: 520px;
  margin-bottom: 1.5rem;
}

.slide-link {
  display: inline-block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.04em;
  transition: opacity 0.2s;
}

.slide-link:hover { opacity: 0.75; }

/* slide reveal — override default reveal for slides */
.project-slide.reveal {
  opacity: 0;
}

.project-slide.reveal.visible {
  opacity: 1;
  transform: none;
}

@media (max-width: 640px) {
  .project-slide { padding: 2rem; }
  .slide-title { font-size: clamp(1.8rem, 7vw, 2.8rem); }
}

/* ===== LIGHT THEME ===== */
[data-theme="light"] {
  --bg: #f5f2ee;
  --surface: #ece8e2;
  --surface2: #e0dbd4;
  --text: #111111;
  --muted: #888;
  --muted2: #666;
  --border: rgba(0,0,0,0.1);
}

.theme-switching,
.theme-switching * {
  transition: background-color 0.35s, color 0.35s, border-color 0.35s !important;
}

[data-theme="light"] .nav-logo,
[data-theme="light"] .nav-links,
[data-theme="light"] .nav-right {
  background: rgba(245,242,238,0.78);
  border-color: rgba(0,0,0,0.1);
  box-shadow: 0 4px 20px rgba(0,0,0,0.09), inset 0 1px 0 rgba(255,255,255,0.9);
}

[data-theme="light"] .nav-links a { color: rgba(0,0,0,0.5); }
[data-theme="light"] .nav-links a:hover {
  color: #000;
  background: rgba(0,0,0,0.07);
}

[data-theme="light"] .btn-ghost {
  background: rgba(255,255,255,0.5);
  border-color: rgba(0,0,0,0.12);
  box-shadow: 0 2px 12px rgba(0,0,0,0.06), inset 0 1px 0 rgba(255,255,255,0.9);
}

[data-theme="light"] .btn-ghost:hover {
  border-color: rgba(0,0,0,0.25);
  background: rgba(255,255,255,0.75);
}

[data-theme="light"] .project-num { color: rgba(0,0,0,0.2); }

[data-theme="light"] .project-card {
  background: rgba(255,255,255,0.55);
  border-color: rgba(255,255,255,0.85);
  box-shadow: 0 4px 24px rgba(0,0,0,0.07), inset 0 1px 0 rgba(255,255,255,0.95);
}

[data-theme="light"] .project-card:hover {
  border-color: rgba(255,255,255,0.95);
  box-shadow: 0 20px 52px rgba(0,0,0,0.1), inset 0 1px 0 rgba(255,255,255,0.95);
}

[data-theme="light"] .project-tag {
  background: rgba(255,255,255,0.55);
  border-color: rgba(0,0,0,0.1);
}

[data-theme="light"] .approach-item {
  background: rgba(255,255,255,0.55);
  border-color: rgba(255,255,255,0.85);
  box-shadow: 0 4px 24px rgba(0,0,0,0.07), inset 0 1px 0 rgba(255,255,255,0.95);
}

[data-theme="light"] .approach-item:hover {
  box-shadow: 0 16px 44px rgba(0,0,0,0.1), inset 0 1px 0 rgba(255,255,255,0.95);
  border-color: rgba(255,255,255,0.95);
}

[data-theme="light"] .skill-item {
  background: rgba(255,255,255,0.6);
  border-color: rgba(0,0,0,0.1);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.95);
}

[data-theme="light"] .nav-logo-mark {
  filter: none;
  mix-blend-mode: normal;
}

/* ===== NAV RIGHT ===== */
.nav-right {
  display: flex;
  align-items: center;
  gap: 0;
  background: rgba(15,15,15,0.72);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 9999px;
  padding: 0.35rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.07);
}

/* ===== THEME TOGGLE ===== */
.theme-toggle {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.45rem 0.6rem;
  display: flex;
  align-items: center;
}

.toggle-track {
  width: 38px;
  height: 22px;
  border-radius: 11px;
  background: var(--surface2);
  border: 1px solid var(--border);
  position: relative;
  display: block;
  transition: background 0.3s, border-color 0.3s;
}

.toggle-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--muted);
  transition: transform 0.3s, background 0.3s;
  display: block;
}

[data-theme="light"] .toggle-thumb {
  transform: translateX(16px);
  background: var(--accent);
}

/* ===== PROJECT MODAL ===== */
.project-card { cursor: pointer; }

.project-modal {
  position: fixed;
  inset: 0;
  z-index: 900;
  background: rgba(0, 0, 0, 0.96);
  display: flex;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.project-modal.open {
  opacity: 1;
  pointer-events: all;
}
.modal-close {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  z-index: 10;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(255,255,255,0.06);
  color: #fff;
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}
.modal-close:hover { background: rgba(255,255,255,0.15); }
.modal-stage {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.modal-img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
  position: relative;
  z-index: 1;
}
.modal-bg {
  position: absolute;
  inset: 0;
}
.modal-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.2);
  background: rgba(0,0,0,0.45);
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}
.modal-nav:hover { background: rgba(0,0,0,0.75); }
.modal-prev { left: 1.25rem; }
.modal-next { right: 1.25rem; }
.modal-bar {
  display: flex;
  gap: 3rem;
  align-items: flex-start;
  padding: 1.5rem 2rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  flex-shrink: 0;
}
.modal-bar-left { flex-shrink: 0; min-width: 220px; }
.modal-bar-meta {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}
.modal-bar-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #fff;
  margin: 0 0 0.75rem;
}
.modal-dots {
  display: flex;
  gap: 0.4rem;
  align-items: center;
}
.modal-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(255,255,255,0.25);
  transition: background 0.2s;
  cursor: pointer;
}
.modal-dot.active { background: var(--accent); }
.modal-bar-desc {
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.7;
  margin: 0;
  flex: 1;
}

@media (max-width: 640px) {
  .modal-bar { flex-direction: column; gap: 1rem; padding: 1.25rem; }
  .modal-bar-left { min-width: unset; }
  .modal-bar-title { font-size: 1rem; margin-bottom: 0.4rem; }
  .modal-prev { left: 0.5rem; }
  .modal-next { right: 0.5rem; }
}

@media (max-width: 640px) {
  #nav { padding: 1.2rem 1.5rem; }
  .nav-links { display: none; }
  .hamburger { display: flex; }
  #hero { padding: 7rem 1.5rem 2rem; }
  .hero-bottom { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
  .container { padding: 0 1.5rem; }
  #about, #work, #approach { padding: 6rem 0; }
  #contact { padding: 6rem 0 4rem; }
  .contact-row { flex-direction: column; }
  .approach-item { padding: 2rem; }
  .footer-inner { flex-direction: column; gap: 0.75rem; text-align: center; }
}
