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

:root {
  --bg: #0a0a0c;
  --surface: #121215;
  --surface-light: #1a1a1f;
  --border: #222228;
  --text: #e8e8ec;
  --text-muted: #b0b0b8;
  --accent: #4f8cff;
  --accent-hover: #6fa0ff;
  --accent-glow: rgba(79, 140, 255, 0.15);
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-display: 'Space Grotesk', 'Inter', sans-serif;
}

html {
  scroll-behavior: smooth;
}

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

/* ── Navbar ── */
.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 2.5rem;
  background: rgba(10, 10, 12, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
}

.nav-logo {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2.5rem;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}

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

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}

/* ── Hero ── */
.hero {
  position: relative;
  min-height: 60vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8rem 2.5rem 4rem;
  overflow: hidden;
}

.hero-backdrop {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 40%, rgba(79, 140, 255, 0.06) 0%, transparent 70%),
    radial-gradient(ellipse 60% 50% at 80% 60%, rgba(120, 80, 255, 0.04) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  max-width: 1400px;
  width: 100%;
  padding: 0 2.5rem;
}

.hero-inner {
  display: flex;
  align-items: center;
  gap: 3.5rem;
}

.hero-text {
  flex: 1;
}

.hero-headshot {
  flex-shrink: 0;
  width: 340px;
  align-self: stretch;
  border-radius: 16px;
  overflow: hidden;
  border: 3px solid var(--border);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(79, 140, 255, 0.1);
  opacity: 0;
  transform: scale(0.9);
  animation: fadeUp 0.6s ease forwards 0.8s;
}

.hero-headshot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-greeting {
  font-size: 1rem;
  font-weight: 500;
  color: var(--accent);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp 0.6s ease forwards 0.2s;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 1.5rem;
}

.hero-line {
  display: block;
  opacity: 0;
  transform: translateY(30px);
  animation: fadeUp 0.6s ease forwards;
}

.hero-line:nth-child(1) { animation-delay: 0.4s; }
.hero-line:nth-child(2) { animation-delay: 0.55s; color: var(--text-muted); }
.hero-line:nth-child(3) { animation-delay: 0.7s; color: var(--text-muted); }

.hero-subtitle {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 540px;
  line-height: 1.7;
  margin-bottom: 2.5rem;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp 0.6s ease forwards 0.9s;
}

.hero-cta {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  opacity: 0;
  transform: translateY(20px);
  animation: fadeUp 0.6s ease forwards 1.1s;
}

.hero-scroll-hint {
  display: none;
}

.scroll-line {
  width: 1px;
  height: 40px;
  background: linear-gradient(to bottom, var(--text-muted), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes fadeUp {
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  to { opacity: 1; }
}

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

/* ── Buttons ── */
.btn {
  display: inline-block;
  padding: 0.75rem 1.75rem;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: var(--font-body);
  text-decoration: none;
  border-radius: 6px;
  transition: all 0.25s ease;
  cursor: pointer;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
}

.btn-primary:hover {
  background: var(--accent-hover);
  box-shadow: 0 4px 24px var(--accent-glow);
}

.btn-outline {
  background: transparent;
  color: var(--text);
  border: 1px solid #fff;
}

.btn-outline:hover {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

/* ── Sections ── */
.section {
  max-width: 1400px;
  margin: 0 auto;
  padding: 6rem 2.5rem;
}

.section-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 3rem;
}

/* ── Projects ── */
.project-list {
  display: flex;
  flex-direction: column;
  gap: 3.5rem;
}

.project-card {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
  transition: border-color 0.35s ease, box-shadow 0.35s ease;
}

.project-card:hover {
  border-color: rgba(79, 140, 255, 0.2);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3);
}

/* Gallery: large image on top, horizontal thumbs below */
.project-gallery {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 4px;
  background: #0e0e11;
}

.gallery-main {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  overflow: hidden;
}

.main-image {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.35s ease;
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  background-color: #0e0e11;
}

.main-image.active {
  opacity: 1;
}

.gallery-thumbs {
  display: flex;
  flex-direction: row;
  gap: 4px;
  height: 72px;
}

.gallery-thumb {
  flex: 1;
  border: 2px solid transparent;
  border-radius: 6px;
  cursor: pointer;
  transition: border-color 0.2s, opacity 0.2s;
  opacity: 0.45;
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  background-color: #0e0e11;
}

.gallery-thumb:hover {
  opacity: 0.75;
}

.gallery-thumb.active {
  border-color: var(--accent);
  opacity: 1;
}

/* Project info panel */
.project-tag {
  display: inline-block;
  padding: 0.3rem 0.75rem;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent);
  background: var(--accent-glow);
  border: 1px solid rgba(79, 140, 255, 0.15);
  border-radius: 4px;
  align-self: flex-start;
}

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

.project-info {
  padding: 2.5rem 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.project-info h4 {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--accent);
  display: inline-block;
}

.project-info p {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.75;
  margin-bottom: 1.25rem;
}

.project-role {
  color: var(--accent) !important;
  font-weight: 600;
  font-size: 1.1rem;
  margin-bottom: 1.25rem;
  letter-spacing: 0.01em;
}

.project-info h5 {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text);
  margin-bottom: 0.6rem;
}

.project-info ul {
  list-style: none;
  margin-bottom: 1.75rem;
}

.project-info ul li {
  position: relative;
  padding-left: 1.1rem;
  color: var(--text);
  font-size: 0.88rem;
  line-height: 1.7;
  margin-bottom: 0.35rem;
}

.project-info ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
}

.btn-sm {
  padding: 0.85rem 2rem;
  font-size: 1rem;
  align-self: flex-start;
}

/* ── About ── */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: stretch;
}
.about-photo {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
}
.about-photo img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.about-text p {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.75;
  margin-bottom: 1rem;
}

.about-disciplines {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.discipline {
  padding: 1.25rem 1.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  transition: border-color 0.25s;
}

.discipline:hover {
  border-color: rgba(79, 140, 255, 0.25);
}

.discipline h4 {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  color: var(--text);
}

.discipline p {
  color: var(--text-muted);
  font-size: 0.85rem;
  line-height: 1.6;
}

/* ── Contact ── */
.section-contact {
  text-align: center;
}

.contact-text {
  color: var(--text-muted);
  font-size: 1.1rem;
  margin-bottom: 2rem;
}

.contact-links {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* ── Footer ── */
.footer {
  text-align: center;
  padding: 2.5rem;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
}

/* ── Scroll reveal ── */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

/* ── Responsive ── */
@media (max-width: 768px) {
  .navbar {
    padding: 1rem 1.5rem;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: rgba(10, 10, 12, 0.95);
    backdrop-filter: blur(16px);
    padding: 1.5rem;
    gap: 1.25rem;
    border-bottom: 1px solid var(--border);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-toggle {
    display: flex;
  }

  .hero {
    padding: 7rem 1.5rem 3rem;
    min-height: 50vh;
  }

  .hero-inner {
    flex-direction: column-reverse;
    gap: 2rem;
    text-align: center;
  }

  .hero-headshot {
    width: 100%;
    height: 240px;
  }

  .hero-cta {
    justify-content: center;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .section {
    padding: 4rem 1.5rem;
  }

  .project-card {
    grid-template-columns: 1fr;
  }

  .gallery-main {
    aspect-ratio: 16 / 9;
  }

  .gallery-thumbs {
    height: 56px;
  }

  .project-info {
    padding: 1.5rem;
  }

  .project-info h4 {
    font-size: 1.35rem;
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .hero-scroll-hint {
    display: none;
  }
}
