:root {
  color-scheme: light;
  --bg: #fff;
  --text: #212121;
  --muted: #777;
  --border: #eee;
  --link: #1565c0;
}

html.dark {
  color-scheme: dark;
  --bg: #212121;
  --text: #dadada;
  --muted: #aaa;
  --border: #424242;
  --link: #42a5f5;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.7;
  transition: background-color .2s, color .2s;
}

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

a:hover { color: var(--link); }

.wrapper {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

.container {
  width: min(90%, 90rem);
  margin: 0 auto;
}

.navigation {
  height: 6rem;
  line-height: 6rem;
}

.navigation-title {
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: .02em;
}

.navigation-list {
  float: right;
  display: flex;
  gap: 2rem;
  margin: 0;
  list-style: none;
}

.navigation-list a { font-size: .95rem; }

.search-item {
  display: flex;
  align-items: center;
}

.search-item pagefind-modal-trigger {
  --pagefind-ui-primary: var(--text);
  --pagefind-ui-text: var(--text);
  --pagefind-ui-background: transparent;
  font-size: .95rem;
  line-height: 1;
}

.menu-button {
  display: none;
  float: right;
  margin-top: 1.75rem;
  border: 0;
  background: transparent;
  color: var(--text);
  font-size: 1.5rem;
}

.theme-toggle {
  position: fixed;
  z-index: 2;
  top: 1rem;
  right: 1rem;
  width: 2.25rem;
  height: 2.25rem;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  font-size: 1.45rem;
}

.content {
  display: flex;
  flex: 1;
  align-items: center;
  padding: 2rem 0;
}

.home, .list-page, .page { width: 100%; }

.centered { text-align: center; }

.post-list ul {
  display: inline-block;
  margin: 0;
  padding: 0;
  list-style: none;
  text-align: left;
}

.post-list li { margin: .8rem 0; }

.post-list .date {
  display: inline-block;
  width: 10rem;
  color: var(--muted);
}

.post-list .title { font-weight: 700; }

hr {
  margin: 3.5rem 0;
  border: 0;
  border-top: 1px solid var(--border);
}

.avatar img {
  width: 18rem;
  height: 18rem;
  border-radius: 50%;
  object-fit: cover;
}

.about h1 {
  margin: 1rem 0 .2rem;
  font-size: 2rem;
}

.about h2 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 400;
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
  padding: 0;
  list-style: none;
}

.social-links a {
  display: inline-grid;
  width: 2.1rem;
  height: 2.1rem;
  place-items: center;
  border-radius: .25rem;
  background: var(--text);
  color: var(--bg);
  font-weight: 800;
}

.list-page, .page { max-width: 52rem; }

.list-page h1, .page h1 { line-height: 1.25; }

.page-meta {
  color: var(--muted);
  font-size: .9rem;
}

.post-taxonomy {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  margin-top: .6rem;
}

.taxonomy-pill {
  display: inline-block;
  padding: .2rem .65rem;
  border-radius: 999px;
  font-size: .78rem;
  font-weight: 500;
  text-decoration: none;
  line-height: 1.5;
  transition: opacity .15s;
}

.taxonomy-category {
  background: var(--accent, #0066cc);
  color: #fff;
}

.taxonomy-tag {
  background: var(--border, #e0e0e0);
  color: var(--text);
}

.taxonomy-category:hover { background: #004fa3; color: #fff; opacity: 1; }
.taxonomy-tag:hover { background: var(--muted, #aaa); color: var(--bg); opacity: 1; }

.page-content a {
  color: var(--link);
  text-decoration: underline;
}

.page-content img { max-width: 100%; }

.post-share {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.post-share h2 {
  margin: 0 0 .9rem;
  font-size: 1rem;
}

.share-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .7rem;
}

.share-button {
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  padding: .48rem .75rem;
  border: 1px solid var(--border);
  border-radius: .35rem;
  color: var(--text);
  font-size: .9rem;
  font-weight: 800;
}

.share-button:hover {
  border-color: var(--link);
  color: var(--link);
}

.share-button span { font-weight: 600; }

.share-linkedin {
  border-color: #0a66c2;
  color: #0a66c2;
}

.contact-intro {
  max-width: 44rem;
  margin-bottom: 2rem;
}

.contact-kicker {
  margin-bottom: .4rem;
  color: var(--muted);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.contact-intro h2 {
  margin: 0 0 .8rem;
  font-size: 1.8rem;
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(16rem, .85fr);
  gap: 1.25rem;
  margin-top: 2rem;
}

.contact-topics,
.contact-card {
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-radius: .65rem;
}

.contact-topics h3,
.contact-card h3 {
  margin-top: 0;
}

.contact-topics ul {
  margin-bottom: 0;
  padding-left: 1.25rem;
}

.contact-topics li { margin: .45rem 0; }

.contact-button {
  display: inline-block;
  margin-top: .5rem;
  padding: .65rem .9rem;
  border-radius: .35rem;
  background: var(--link);
  color: #fff !important;
  font-size: .92rem;
  font-weight: 700;
  text-decoration: none !important;
}

.contact-button:hover {
  color: #fff;
  filter: brightness(.9);
}

.footer {
  padding: 2rem 0;
  color: var(--muted);
  font-size: .85rem;
  text-align: center;
}

@media (max-width: 768px) {
  .navigation { height: auto; }
  .navigation-list {
    display: none;
    float: none;
    gap: 0;
    padding: 0 0 1rem;
    line-height: 2.4;
    text-align: center;
  }
  .search-item { justify-content: center; }
  .navigation-list.open { display: block; }
  .menu-button { display: block; }
  .post-list .date {
    display: block;
    width: auto;
    font-size: .85rem;
  }
  .avatar img {
    width: 14rem;
    height: 14rem;
  }
  .contact-grid { grid-template-columns: 1fr; }
}
