/* ===========================================================
   Onur Şerin — personal site
   Minimal, single-column layout with light/dark support.
   =========================================================== */

:root {
  --bg:        #ffffff;
  --text:      #1a1a1a;
  --muted:     #6b7280;
  --link:      #0d6efd;
  --link-hover:#0a58ca;
  --rule:      #ececec;
  --maxw:      40rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:        #111315;
    --text:      #e6e6e6;
    --muted:     #9aa0a6;
    --link:      #6ea8fe;
    --link-hover:#9ec5fe;
    --rule:      #26292c;
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
               Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji", sans-serif;
  font-size: 18px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 3.5rem 1.25rem 5rem;
}

/* ---------- Links ---------- */
a {
  color: var(--link);
  text-decoration: none;
}
a:hover { color: var(--link-hover); text-decoration: underline; }

/* ---------- Masthead / nav ---------- */
.masthead {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem 1.25rem;
  margin-bottom: 3rem;
}
.nav { display: flex; gap: 1rem; }
.nav-link {
  font-size: 0.95rem;
  color: var(--muted);
}
.nav-link:hover { color: var(--text); text-decoration: none; }
.nav-link.is-active { color: var(--text); font-weight: 600; }

/* ---------- Intro ---------- */
.intro { margin-bottom: 3rem; }
.avatar {
  display: block;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  margin-bottom: 1.25rem;
}
.intro p { margin: 0 0 0.75rem; }
.muted { color: var(--muted); font-size: 0.95rem; }

/* ---------- Sub-page heading + prose ---------- */
.page-title {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 0.5rem;
}
.page-lead {
  margin: 0 0 2.5rem;
  color: var(--muted);
}
.prose p { margin: 0 0 1.1rem; }
.prose a { text-decoration: underline; }

/* Year label for grouped lists */
.year {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin: 2rem 0 0.75rem;
}

/* ---------- Content blocks ---------- */
.block { margin-bottom: 2.75rem; }
.block-title {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin: 0 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--rule);
}

.list { list-style: none; margin: 0; padding: 0; }
.list > li { margin-bottom: 1.1rem; }

.item-title {
  font-weight: 600;
  color: var(--text);
}
.item-title:hover { color: var(--link); text-decoration: none; }

.item-desc {
  margin: 0.1rem 0 0;
  color: var(--muted);
  font-size: 0.97rem;
  line-height: 1.55;
}

/* Writing rows: title left, date right ---------- */
.post {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
}
.item-date {
  flex: none;
  color: var(--muted);
  font-size: 0.9rem;
  font-variant-numeric: tabular-nums;
}

.more {
  display: inline-block;
  margin-top: 0.25rem;
  font-size: 0.95rem;
}

/* ---------- Footer ---------- */
.footer {
  margin-top: 4rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 0.9rem;
}
.footer p { margin: 0; }
.heart { color: #e25555; }

/* ---------- Small screens ---------- */
@media (max-width: 28rem) {
  .wrap { padding-top: 2.5rem; }
  .post { flex-direction: column; gap: 0.1rem; }
}
