:root {
  --bg: #f6f1e8;
  --surface: #fffdf8;
  --ink: #18231d;
  --muted: #4b5b52;
  --line: #d7d0c2;
  --accent: #e04f23;
  --accent-alt: #1f7f63;
  --shadow: 0 20px 60px rgba(24, 35, 29, 0.14);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Manrope", sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.5;
  overflow-x: hidden;
}

.bg-layer {
  position: fixed;
  inset: auto;
  pointer-events: none;
  z-index: -1;
  filter: blur(3px);
}

.bg-layer-a {
  width: 70vmax;
  height: 70vmax;
  top: -35vmax;
  right: -10vmax;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(224, 79, 35, 0.34) 0%, rgba(224, 79, 35, 0) 72%);
}

.bg-layer-b {
  width: 70vmax;
  height: 70vmax;
  bottom: -30vmax;
  left: -20vmax;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(31, 127, 99, 0.3) 0%, rgba(31, 127, 99, 0) 70%);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  width: min(1100px, calc(100% - 2rem));
  margin: 1rem auto 0;
  padding: 0.85rem 1.2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border: 1px solid color-mix(in oklab, var(--line), white 22%);
  border-radius: 999px;
  background: rgba(255, 250, 241, 0.82);
  backdrop-filter: blur(10px);
}

.brand {
  text-decoration: none;
  color: var(--ink);
  font-weight: 800;
  letter-spacing: 0.02em;
}

.site-header nav {
  display: flex;
  gap: 0.9rem;
}

.site-header nav a {
  text-decoration: none;
  color: var(--muted);
  font-weight: 600;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  transition: background 0.25s ease, color 0.25s ease;
}

.site-header nav a:hover {
  background: #f2ece1;
  color: var(--ink);
}

main {
  width: min(1100px, calc(100% - 2rem));
  margin: 2.5rem auto 4rem;
  display: grid;
  gap: 5rem;
}

.hero h1,
h2 {
  margin: 0;
  font-family: "Instrument Serif", serif;
  font-weight: 400;
  line-height: 1.02;
}

.hero h1 {
  font-size: clamp(2.4rem, 6vw, 5rem);
  max-width: 14ch;
}

.hero h1 span {
  color: var(--accent-alt);
  font-style: italic;
}

.hero-copy {
  max-width: 60ch;
  margin-top: 1.1rem;
  color: var(--muted);
  font-size: 1.06rem;
}

.eyebrow {
  margin: 0 0 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.76rem;
  font-weight: 800;
  color: var(--accent);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.4rem;
}

.btn {
  text-decoration: none;
  font-weight: 700;
  padding: 0.75rem 1.15rem;
  border-radius: 999px;
  border: 1px solid transparent;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--ink);
  color: #fff;
  box-shadow: 0 10px 24px rgba(24, 35, 29, 0.25);
}

.btn-secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--ink);
}

.stats {
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.7rem;
}

.stats li {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 1rem;
}

.stats strong {
  display: block;
  font-size: 1.25rem;
}

.stats span {
  font-size: 0.88rem;
  color: var(--muted);
}

.section-head h2 {
  font-size: clamp(1.9rem, 4vw, 3.2rem);
}

.projects-grid {
  margin-top: 1.4rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1rem;
}

.project-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.95rem;
  padding: 1.05rem;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: color-mix(in oklab, var(--surface), white 15%);
  box-shadow: var(--shadow);
  transform-origin: center;
  transition: transform 0.25s ease;
}

.project-card:hover {
  transform: translateY(-4px) rotate(-0.35deg);
}

.project-card h3 {
  margin: 0;
  font-size: 1.08rem;
}

.project-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.project-meta {
  display: flex;
  gap: 0.75rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.project-card a {
  text-decoration: none;
  color: var(--accent-alt);
  font-weight: 700;
}

.about p,
.contact p {
  max-width: 66ch;
  color: var(--muted);
}

.skill-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.skill-chips span {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 999px;
  padding: 0.45rem 0.8rem;
  font-size: 0.88rem;
  font-weight: 700;
}

footer {
  width: min(1100px, calc(100% - 2rem));
  margin: 0 auto 2rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

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

@media (max-width: 760px) {
  .site-header {
    border-radius: 16px;
    padding: 0.85rem;
  }

  .site-header nav {
    gap: 0.2rem;
  }

  .site-header nav a {
    font-size: 0.83rem;
    padding: 0.3rem 0.55rem;
  }

  .stats {
    grid-template-columns: 1fr;
  }
}
