@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&display=swap');

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

:root {
  --bg:           #f5f0e8;
  --text:         #2c2c2c;
  --green:        #2d4a3e;
  --green-hover:  #3d6454;
  --muted:        #7a7068;
  --border:       #d8d0c5;
  --card:         #ece7dd;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ── Site nav ─────────────────────────── */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 36px;
  padding: 16px 48px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.nav-item {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  padding: 0;
  transition: color 0.15s;
}

.nav-item:hover { color: var(--green); }

/* ── Profile section ──────────────────── */
.profile {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 52px 24px 52px;
  max-width: 580px;
  margin: 0 auto;
}

.avatar-wrap {
  position: relative;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--green);
  margin-bottom: 28px;
  flex-shrink: 0;
}

.avatar {
  width: 133.33%;
  height: 133.33%;
  margin-left: -16.67%;
  margin-top: -16.67%;
  object-fit: cover;
  object-position: center center;
  display: block;
}

.profile-name {
  font-size: 1.9rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 18px;
}

.profile-bio {
  font-size: 1rem;
  font-weight: 400;
  color: var(--muted);
  line-height: 1.8;
  max-width: 460px;
  margin-bottom: 32px;
}

/* ── Social buttons ───────────────────── */
.social-buttons {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 0.84rem;
  font-weight: 500;
  text-decoration: none;
  padding: 10px 22px;
  border-radius: 8px;
  border: 1.5px solid transparent;
  transition: all 0.15s;
  line-height: 1;
  font-family: inherit;
  cursor: pointer;
}

.social-btn svg {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
}

/* Side-by-side CTA row */
.cta-row {
  display: flex;
  gap: 10px;
}

.cta-row .social-btn {
  justify-content: center;
  white-space: nowrap;
  padding: 13px 18px;
  font-size: 0.86rem;
}

/* Primary CTA */
.btn-work {
  background: var(--green);
  color: #fff;
  border-color: var(--green);
}

.btn-work:hover {
  background: var(--green-hover);
  border-color: var(--green-hover);
}

/* Substack secondary CTA */
.btn-substack-cta {
  background: transparent;
  color: var(--green);
  border-color: var(--green);
}

.btn-substack-cta:hover {
  background: var(--green);
  color: #fff;
}


/* ── Modal ────────────────────────────── */
.modal {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: var(--bg);
  overflow-y: auto;
  opacity: 0;
  pointer-events: none;
  transform: translateY(16px);
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.modal.open {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0);
}

.modal-close {
  position: fixed;
  top: 22px;
  right: 28px;
  background: var(--card);
  border: none;
  cursor: pointer;
  color: var(--muted);
  border-radius: 8px;
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, color 0.15s;
  z-index: 301;
}

.modal-close:hover { background: var(--border); color: var(--text); }
.modal-close svg { width: 20px; height: 20px; display: block; }

.modal-body {
  max-width: 660px;
  margin: 0 auto;
  padding: 60px 32px 120px;
}

/* ── Section divider ──────────────────── */
.section-divider {
  border: none;
  border-top: 1px solid var(--border);
  max-width: 580px;
  margin: 8px auto 0;
}

/* ── Writing / feed section ───────────── */
.feed-section {
  max-width: 580px;
  margin: 0 auto;
  padding: 44px 24px 100px;
}

.feed-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.feed-label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--green);
}

.feed-link {
  font-size: 0.76rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.15s;
}

.feed-link:hover { color: var(--green); }

/* Post list */
.post-list { border-top: 1px solid var(--border); }

.post-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
  text-decoration: none;
  color: var(--text);
}

.post-item:hover .post-title { color: var(--green); }

.post-title {
  font-size: 0.95rem;
  font-weight: 400;
  flex: 1;
  transition: color 0.15s;
}

.post-arrow {
  color: var(--muted);
  font-size: 0.8rem;
  flex-shrink: 0;
  transition: transform 0.15s, color 0.15s;
}

.post-item:hover .post-arrow {
  color: var(--green);
  transform: translateX(3px);
}

.post-date {
  font-size: 0.72rem;
  color: var(--muted);
  white-space: nowrap;
}

.feed-status {
  font-size: 0.88rem;
  color: var(--muted);
  padding: 20px 0;
  font-weight: 400;
}

/* ── Work page ────────────────────────── */
.work-page {
  max-width: 680px;
  margin: 0 auto;
  padding: 52px 32px 120px;
}

.page-eyebrow {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--green);
  margin-bottom: 10px;
}

.page-title {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 12px;
}

.page-subhead {
  font-size: 1rem;
  color: var(--muted);
  font-weight: 400;
  max-width: 540px;
  line-height: 1.75;
  margin-bottom: 14px;
}

.page-subhead:last-of-type { margin-bottom: 64px; }

/* Timeline */
.timeline { border-top: 1px solid var(--border); }

.tl-item {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 32px;
  padding: 40px 0;
  border-bottom: 1px solid var(--border);
}

.tl-meta { padding-top: 2px; }

.tl-dates {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--muted);
  line-height: 1.6;
  margin-bottom: 4px;
}

.tl-location {
  font-size: 0.7rem;
  color: var(--muted);
  opacity: 0.75;
  margin-bottom: 10px;
}

.tl-badge {
  display: inline-block;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--green);
  border: 1px solid var(--green);
  padding: 3px 7px;
  border-radius: 3px;
}

.tl-role {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 3px;
}

.tl-company {
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 14px;
}

.tl-body {
  font-size: 0.93rem;
  font-weight: 400;
  color: var(--text);
  line-height: 1.7;
  margin-bottom: 14px;
}

.tl-bullets {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tl-bullets li {
  font-size: 0.91rem;
  font-weight: 400;
  line-height: 1.65;
  padding-left: 16px;
  position: relative;
  color: var(--text);
}

.tl-bullets li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.65em;
  width: 5px;
  height: 1.5px;
  background: var(--green);
}

/* Education */
/* ── Hard skills block ────────────────── */
.skills-block {
  border-left: 2.5px solid var(--green);
  padding-left: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-bottom: 64px;
}

.skills-para {
  font-size: 0.95rem;
  font-weight: 400;
  color: var(--text);
  line-height: 1.8;
}

.skills-stacks {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding-top: 4px;
}

.stack-item {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.stack-co {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--green);
  min-width: 96px;
  flex-shrink: 0;
}

.stack-desc {
  font-size: 0.88rem;
  color: var(--muted);
  font-weight: 400;
}

.edu-section-label {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--green);
  margin: 64px 0 24px;
}

.edu-block {
  border-left: 2.5px solid var(--green);
  padding-left: 20px;
}

.edu-degree {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 3px;
}

.edu-uni {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 14px;
}

.edu-bullets {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.edu-bullets li {
  font-size: 0.91rem;
  font-weight: 400;
  line-height: 1.65;
  padding-left: 14px;
  position: relative;
}

.edu-bullets li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.65em;
  width: 5px;
  height: 1px;
  background: var(--muted);
}

/* ── Social icons bar (replaces footer) ─ */
.social-icons-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 24px;
  padding: 40px 0 60px;
  border-top: 1px solid var(--border);
  margin-top: 8px;
}

.social-icon {
  display: flex;
  align-items: center;
  color: var(--muted);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  transition: color 0.15s;
}

.social-icon:hover { color: var(--green); }
.social-icon svg { width: 20px; height: 20px; display: block; }

/* ── Responsive ───────────────────────── */
@media (max-width: 640px) {
  nav { padding: 16px 20px; }
  .profile { padding: 52px 20px 40px; }
  .avatar-wrap { width: 98px; height: 98px; }
  .profile-name { font-size: 1.5rem; }
  .feed-section { padding: 36px 20px 80px; }
  .work-page { padding: 52px 20px 80px; }
  footer { flex-direction: column; gap: 12px; padding: 20px; text-align: center; }

  .tl-item {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 32px 0;
  }
}
