:root {
  color-scheme: light;
  --ink: #17201d;
  --muted: #64706a;
  --paper: #fbfbf8;
  --line: #d9ded8;
  --forest: #19443d;
  --teal: #2b7a78;
  --coral: #b85742;
  --gold: #b08d34;
  --white: #ffffff;
  --shadow: 0 18px 55px rgba(23, 32, 29, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--paper);
  color: var(--ink);
}

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

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

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px clamp(18px, 5vw, 64px);
  background: rgba(251, 251, 248, 0.84);
  border-bottom: 1px solid rgba(217, 222, 216, 0.8);
  backdrop-filter: blur(18px);
}

.brand {
  font-size: 0.95rem;
  font-weight: 800;
}

nav {
  display: flex;
  gap: clamp(14px, 3vw, 32px);
  color: var(--muted);
  font-size: 0.93rem;
}

nav a:hover {
  color: var(--ink);
}

.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: end;
  overflow: hidden;
  padding: 120px clamp(20px, 6vw, 76px) 64px;
  background: #101614;
  color: var(--white);
}

.hero-backdrop {
  position: absolute;
  inset: 0;
}

.hero-backdrop::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(16, 22, 20, 0.94), rgba(16, 22, 20, 0.72) 42%, rgba(16, 22, 20, 0.36)),
    linear-gradient(0deg, rgba(16, 22, 20, 0.85), transparent 48%);
}

.hero-backdrop img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.78;
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(850px, 100%);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--coral);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #ffca8a;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 850px;
  margin-bottom: 22px;
  font-size: clamp(3rem, 8.4vw, 7.4rem);
  line-height: 0.92;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 18px;
  font-size: clamp(2rem, 5vw, 4.3rem);
  line-height: 1;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 10px;
  font-size: 1.15rem;
}

.hero-copy {
  max-width: 680px;
  color: rgba(255, 255, 255, 0.82);
  font-size: clamp(1rem, 2vw, 1.24rem);
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border: 1px solid rgba(255, 255, 255, 0.36);
  border-radius: 8px;
  color: var(--white);
  font-weight: 760;
}

.button.primary {
  background: #ffffff;
  color: #14201c;
}

.button:hover {
  transform: translateY(-1px);
}

.section {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: 84px 0;
}

.quick-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  width: min(1180px, calc(100% - 40px));
  margin-top: -28px;
  padding: 0;
  position: relative;
  z-index: 2;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--line);
  box-shadow: var(--shadow);
}

.quick-stats div {
  min-height: 130px;
  padding: 24px;
  background: var(--white);
}

.quick-stats span,
.timeline span,
.project-meta {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 750;
}

.quick-stats strong {
  display: block;
  margin-top: 12px;
  font-size: clamp(1rem, 2vw, 1.22rem);
  line-height: 1.35;
}

.section-heading {
  max-width: 860px;
  margin-bottom: 34px;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.project-card {
  display: grid;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 10px 28px rgba(23, 32, 29, 0.08);
}

.project-card.featured {
  grid-column: 1 / -1;
  grid-template-columns: minmax(0, 1.08fr) minmax(340px, 0.92fr);
}

.project-card img {
  width: 100%;
  height: 100%;
  min-height: 260px;
  object-fit: cover;
  background: #202927;
}

.project-body {
  display: flex;
  min-height: 280px;
  flex-direction: column;
  justify-content: center;
  padding: clamp(24px, 4vw, 42px);
}

.project-body p {
  color: var(--muted);
  line-height: 1.65;
}

.project-body a {
  width: fit-content;
  margin-top: 8px;
  color: var(--teal);
  font-weight: 800;
}

.project-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-bottom: 16px;
}

.project-meta span {
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f6f7f3;
}

.split-section,
.two-column,
.more-projects,
.contact-section {
  display: grid;
  grid-template-columns: minmax(240px, 0.72fr) minmax(0, 1.28fr);
  gap: clamp(28px, 6vw, 72px);
  align-items: start;
}

.timeline {
  display: grid;
  gap: 18px;
}

.timeline article,
.list-panel {
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.timeline p,
.list-panel p {
  color: var(--muted);
  line-height: 1.6;
}

.list-panel p {
  margin-bottom: 18px;
}

.list-panel p:last-child {
  margin-bottom: 0;
}

.repo-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.repo-links a {
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  color: var(--forest);
  font-weight: 780;
}

.contact-section {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto 40px;
  padding: clamp(30px, 6vw, 54px);
  border-radius: 8px;
  background: var(--forest);
  color: var(--white);
}

.contact-section h2 {
  margin-bottom: 0;
}

.contact-links {
  display: grid;
  gap: 14px;
  align-self: center;
}

.contact-links a {
  overflow-wrap: anywhere;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.25);
  color: rgba(255, 255, 255, 0.86);
  font-weight: 750;
}

@media (max-width: 860px) {
  .site-header {
    position: absolute;
    align-items: flex-start;
  }

  nav {
    display: none;
  }

  .hero {
    min-height: 94vh;
    padding-top: 112px;
  }

  .quick-stats,
  .project-grid,
  .project-card.featured,
  .split-section,
  .two-column,
  .more-projects,
  .contact-section {
    grid-template-columns: 1fr;
  }

  .quick-stats {
    margin-top: 0;
    width: 100%;
    border-radius: 0;
  }

  .section,
  .contact-section {
    width: min(100% - 28px, 1180px);
  }

  .project-card.featured {
    display: grid;
  }
}

@media (max-width: 520px) {
  .hero {
    padding-left: 16px;
    padding-right: 16px;
  }

  h1 {
    font-size: 3rem;
  }

  h2 {
    font-size: 2.25rem;
  }

  .project-body,
  .timeline article,
  .list-panel {
    padding: 20px;
  }

  .button {
    width: 100%;
  }
}
