:root {
  --bg: #f5f7f5;
  --text: #1A1A1A;
  --text-muted: rgba(26, 26, 26, 0.62);
  --border: rgba(26, 26, 26, 0.16);
  --bar-idle: rgba(26, 26, 26, 0.28);
  --accent: #3F4F3D;
  --accent-tint: rgba(63, 79, 61, 0.05);
  --error: #B3261E;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14160f;
    --text: #F5F7F5;
    --text-muted: rgba(245, 247, 245, 0.62);
    --border: rgba(245, 247, 245, 0.16);
    --bar-idle: rgba(245, 247, 245, 0.28);
    --accent: #8CA686;
    --accent-tint: rgba(140, 166, 134, 0.08);
    --error: #E2867E;
  }

  .wordmark {
    filter: invert(1);
  }
}

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Josefin Sans', sans-serif;
  font-weight: 300;
  font-size: 18px;
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

button {
  font-family: inherit;
}

.page {
  flex: 1;
  width: 100%;
  max-width: 760px;
  margin: 0;
  padding: 56px clamp(24px, 8vw, 120px) 64px;
}

/* Hero */

.hero {
  margin-bottom: 20px;
}

.wordmark {
  width: 200px;
  height: auto;
  display: block;
}

.tagline {
  margin: 20px 0 0;
  font-size: 18px;
  color: var(--text-muted);
  letter-spacing: 0.01em;
}

.hero--sub {
  margin-bottom: 56px;
}

.wordmark-link {
  display: inline-block;
}

/* Intro */

.intro {
  margin-bottom: 40px;
}

.note-text {
  margin: 0 0 16px;
  font-weight: 300;
}

.note-lead {
  font-weight: 400;
}

.note-signoff {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}

.note-photo {
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
}

.note-email {
  font-size: 15px;
  text-underline-offset: 2px;
}

.note-email:hover,
.note-email:focus-visible {
  text-decoration: underline;
}

.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 0 0 40px;
}

/* About */

.page--about {
  max-width: 900px;
}

.about {
  display: flex;
  align-items: center;
  gap: 40px;
}

.about-photo {
  flex: none;
  display: block;
  width: 220px;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: center;
}

.about-photo--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 14px;
}

.about-text {
  flex: 1;
  min-width: 0;
  margin: 0;
  max-width: 60ch;
  font-weight: 300;
}

.about-text-lead {
  font-weight: 400;
}

@media (max-width: 560px) {
  .about {
    flex-direction: column;
    gap: 24px;
  }

  .about-photo {
    width: 160px;
  }
}

/* Project page */

.page--project {
  max-width: 900px;
}

.project {
  margin-bottom: 40px;
}

.project-title {
  margin: 0 0 16px;
  font-size: 28px;
  font-weight: 400;
  letter-spacing: 0.01em;
}

.project-desc {
  margin: 0 0 16px;
  font-weight: 300;
  max-width: 60ch;
}

.project-signup {
  max-width: 420px;
}

/* Products */

.products {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.products-title {
  margin: 0;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.product {
  display: block;
  padding: 24px 26px;
  border: 1px solid var(--border);
  border-left: 3px solid var(--bar-idle);
  background: transparent;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.product:hover,
.product:focus-visible {
  border-color: var(--border);
  border-left-color: var(--accent);
  background: var(--accent-tint);
}

.product-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}

.product-name {
  font-size: 20px;
  letter-spacing: 0.01em;
}

.product-tag {
  flex: none;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  border: 1px solid var(--border);
  padding: 3px 8px;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.product:hover .product-tag,
.product:focus-visible .product-tag {
  border-color: var(--accent);
  color: var(--accent);
}

.product-desc {
  margin: 10px 0 0;
  font-size: 15px;
  font-weight: 300;
  max-width: 46ch;
}

/* Footer */

.site-footer {
  border-top: 1px solid var(--border);
}

.footer-inner {
  max-width: 760px;
  margin: 0;
  padding: 48px clamp(24px, 8vw, 120px) 40px;
}

.sign-off {
  margin: 32px 0 0;
  font-size: 13px;
  color: var(--text-muted);
}

.about-link {
  text-underline-offset: 2px;
}

.about-link:hover,
.about-link:focus-visible {
  text-decoration: underline;
}

@media (max-width: 480px) {
  .page {
    padding-top: 40px;
  }

  .hero {
    margin-bottom: 32px;
  }
}
