:root {
  --text: #171717;
  --muted: #666;
  --soft: #f7f7f7;
  --line: #e7e7e7;
  --accent: #e64b67;
  --white: #fff;
  --shadow: 0 22px 48px rgba(20, 20, 20, 0.11);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background: var(--white);
  font-family: "Courier New", Courier, monospace;
  font-size: 15px;
  line-height: 1.7;
}

main {
  flex: 1;
}

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

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

button {
  font: inherit;
}

.site-header {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) auto minmax(90px, 0.45fr);
  align-items: center;
  gap: 20px;
  width: min(1440px, calc(100% - 48px));
  margin: 0 auto;
  padding: 24px 0;
}

.brand {
  justify-self: center;
  font-size: clamp(1.35rem, 3vw, 2rem);
  line-height: 1;
  letter-spacing: 0;
}

.nav-left,
.contact-link {
  display: flex;
  gap: 24px;
  align-items: center;
  font-size: clamp(1rem, 0.95vw, 1.1rem);
}

.nav-left {
  flex-wrap: wrap;
}

.nav-left a,
.contact-link {
  border-bottom: 1px solid transparent;
  padding-bottom: 3px;
}

.nav-left a:hover,
.contact-link:hover,
.nav-left a[aria-current="page"] {
  border-bottom-color: var(--text);
}

.contact-link {
  justify-self: end;
}

.menu-toggle {
  display: none;
  justify-self: end;
  border: 1px solid var(--text);
  border-radius: 999px;
  background: var(--white);
  padding: 7px 16px;
}

.hero-section {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  isolation: isolate;
  overflow: hidden;
  width: 100%;
  min-height: calc(100vh - 124px);
  margin: 8px 0 64px;
  padding: clamp(56px, 10vw, 120px) 24px;
  background: var(--text);
}

.hero-section::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    90deg,
    rgba(0, 0, 0, 0.72) 0%,
    rgba(0, 0, 0, 0.42) 45%,
    rgba(0, 0, 0, 0.2) 100%
  );
  content: "";
}

.hero-copy {
  max-width: 780px;
  color: var(--white);
  text-align: center;
}

.hero-copy h1 {
  margin: 0 0 24px;
  font-size: clamp(3rem, 7vw, 6.4rem);
  line-height: 1.02;
  font-weight: 700;
}

.hero-copy p {
  margin: 0 0 20px;
  color: var(--white);
}

.section-kicker,
section > h2 {
  margin: 0 0 34px;
  text-align: center;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.hero-copy .section-kicker {
  text-align: center;
  margin-bottom: 14px;
  color: var(--white);
}

.button-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 138px;
  min-height: 34px;
  border: 1px solid var(--text);
  border-radius: 999px;
  padding: 7px 18px;
  font-size: 0.86rem;
  transition: background 160ms ease, color 160ms ease;
}

.button-link:hover {
  background: var(--text);
  color: var(--white);
}

.hero-copy .button-link {
  border-color: var(--white);
  color: var(--white);
}

.hero-copy .button-link:hover {
  background: var(--white);
  color: var(--text);
}

.hero-image {
  position: absolute;
  inset: 0;
  z-index: -2;
  margin: 0;
}

.hero-image img,
.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-video {
  background: var(--soft);
}

.profile-section,
.writing-section,
.resume-section,
.page-hero,
.filter-section,
.feature-grid {
  width: min(1240px, calc(100% - 72px));
  margin: 0 auto 110px;
}

.profile-grid,
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(34px, 4vw, 58px);
}

.filter-section .feature-grid {
  width: 100%;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.profile-card,
.feature-card {
  text-align: center;
}

.profile-card img,
.feature-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: center;
  margin-bottom: 28px;
}

.feature-card img.image-cycling {
  object-position: center 62%;
}

.feature-card img.image-travel,
.feature-card img.image-hiking {
  object-position: center bottom;
}

.profile-card h3,
.feature-card h2 {
  margin: 0 0 14px;
  font-size: clamp(1.2rem, 1.4vw, 1.42rem);
  font-weight: 700;
}

.profile-card p,
.feature-card p,
.page-hero p,
.writing-card p {
  margin: 0;
  color: var(--muted);
  font-size: clamp(1rem, 1vw, 1.1rem);
  line-height: 1.85;
}

.standalone-section {
  padding-top: 66px;
}

.writing-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(44px, 5vw, 76px);
}

.writing-card {
  border: 1px solid var(--line);
  background: var(--white);
}

.writing-card.elevated {
  box-shadow: var(--shadow);
}

.writing-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.writing-card div {
  padding: 34px 40px 50px;
}

.writing-card time {
  display: block;
  margin-bottom: 16px;
  color: var(--muted);
  font-size: 1rem;
}

.writing-card h3 {
  margin: 0 0 20px;
  font-size: clamp(1.65rem, 2.2vw, 2.25rem);
  line-height: 1.3;
  font-weight: 400;
  letter-spacing: 0.05em;
}

.writing-card a {
  display: inline-block;
  margin-top: 20px;
  color: var(--accent);
}

.resume-section {
  text-align: center;
}

.download-row {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  width: min(560px, 100%);
  margin: 12px auto;
  padding: 12px 18px;
  background: var(--soft);
  text-align: left;
}

.download-row span:last-child {
  color: var(--accent);
}

.page-hero {
  padding-top: 66px;
  text-align: center;
}

.page-hero h1 {
  max-width: 960px;
  margin: 0 auto 22px;
  font-size: clamp(2.8rem, 6.2vw, 5.4rem);
  line-height: 1.08;
}

.page-hero p {
  max-width: 820px;
  margin: 0 auto;
}

.filter-controls {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 44px;
}

.filter-button {
  min-width: 118px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--white);
  padding: 9px 16px;
  cursor: pointer;
}

.filter-button.active,
.filter-button:hover {
  border-color: var(--text);
  background: var(--text);
  color: var(--white);
}

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

.four-up {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.site-footer {
  margin-top: auto;
  background: #181818;
  color: var(--white);
  padding: 28px 24px;
  text-align: center;
  font-size: 0.78rem;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 1100px) {
  .filter-section .feature-grid,
  .four-up {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .site-header {
    grid-template-columns: 1fr auto;
  }

  .brand {
    justify-self: start;
    grid-column: 1;
    grid-row: 1;
  }

  .menu-toggle {
    display: inline-flex;
    grid-column: 2;
    grid-row: 1;
  }

  .contact-link {
    display: none;
  }

  .nav-left {
    display: none;
    grid-column: 1 / -1;
    grid-row: 2;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding-top: 18px;
  }

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

  .hero-section,
  .profile-grid,
  .feature-grid,
  .filter-section .feature-grid,
  .four-up,
  .writing-grid {
    grid-template-columns: 1fr;
  }

  .hero-section {
    width: 100%;
    min-height: calc(100vh - 112px);
    margin-top: 16px;
    padding: 56px 20px;
  }

  .hero-copy h1 {
    font-size: clamp(2.5rem, 12vw, 4.2rem);
  }

  .profile-section,
  .writing-section,
  .resume-section,
  .page-hero,
  .filter-section,
  .feature-grid {
    margin-bottom: 86px;
  }
}

@media (max-width: 560px) {
  .site-header,
  .profile-section,
  .writing-section,
  .resume-section,
  .page-hero,
  .filter-section,
  .feature-grid {
    width: min(100% - 30px, 980px);
  }

  .download-row {
    flex-direction: column;
  }
}
