:root {
  color-scheme: light;
  --bg: #f7f4ed;
  --surface: #fffdfa;
  --surface-strong: #ffffff;
  --ink: #252a2e;
  --muted: #697077;
  --line: #ded7cb;
  --teal: #126a6f;
  --teal-dark: #0b4549;
  --coral: #d56f4d;
  --gold: #b58a2b;
  --shadow: 0 18px 55px rgba(40, 36, 28, 0.12);
  --radius: 8px;
  --max: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", Arial, sans-serif;
  line-height: 1.65;
}

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

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 0 clamp(18px, 4vw, 54px);
  background: rgba(247, 244, 237, 0.9);
  border-bottom: 1px solid rgba(222, 215, 203, 0.78);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  color: #fff;
  background: var(--teal);
  border-radius: 50%;
  font-family: Georgia, serif;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 26px;
  color: #3e464c;
  font-size: 15px;
}

.site-nav a {
  padding: 8px 0;
}

.site-nav a:hover,
.site-footer a:hover {
  color: var(--teal);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 8px;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: var(--ink);
}

.hero {
  position: relative;
  min-height: min(690px, calc(100vh - 72px));
  overflow: hidden;
  background: #1d2528;
}

.hero img {
  width: 100%;
  height: min(690px, calc(100vh - 72px));
  min-height: 520px;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(20, 27, 29, 0.82), rgba(20, 27, 29, 0.48) 42%, rgba(20, 27, 29, 0.1)),
    linear-gradient(0deg, rgba(0, 0, 0, 0.38), rgba(0, 0, 0, 0.02) 46%);
}

.hero-content {
  position: absolute;
  top: 50%;
  left: clamp(20px, 7vw, 96px);
  width: min(650px, calc(100% - 40px));
  transform: translateY(-48%);
  color: #fffdfa;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--coral);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 720px;
  margin: 0;
  font-size: clamp(38px, 7vw, 78px);
  line-height: 1.08;
  letter-spacing: 0;
}

.hero-copy {
  max-width: 610px;
  margin: 22px 0 0;
  color: rgba(255, 253, 250, 0.88);
  font-size: clamp(16px, 2vw, 19px);
}

.hero-actions,
.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 800;
  cursor: pointer;
}

.button.primary {
  color: #fff;
  background: var(--teal);
}

.button.secondary {
  color: #fffdfa;
  border-color: rgba(255, 255, 255, 0.46);
  background: rgba(255, 255, 255, 0.08);
}

.section {
  width: min(var(--max), calc(100% - 36px));
  margin: 0 auto;
}

.stats-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin-top: -34px;
  position: relative;
  z-index: 2;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--line);
  box-shadow: var(--shadow);
}

.stats-strip div {
  padding: 22px;
  background: var(--surface-strong);
}

.stats-strip strong {
  display: block;
  color: var(--teal-dark);
  font-size: 28px;
  line-height: 1.1;
}

.stats-strip span {
  color: var(--muted);
  font-size: 14px;
}

.main-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 32px;
  padding: 84px 0 44px;
}

.section-heading {
  margin-bottom: 24px;
}

.section-heading h2,
.split-section h2,
.contact-section h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.16;
}

.post-tools {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.search-box,
.subscribe-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

input {
  width: 100%;
  min-height: 44px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
  color: var(--ink);
  font: inherit;
}

.filter-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-tabs button {
  min-height: 38px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  cursor: pointer;
  font-weight: 700;
}

.filter-tabs button.active {
  color: #fff;
  background: var(--teal-dark);
  border-color: var(--teal-dark);
}

.post-list {
  display: grid;
  gap: 16px;
}

.post-card,
.profile-card,
.side-panel,
.project-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface-strong);
}

.post-card {
  padding: 24px;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.post-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 36px rgba(33, 38, 40, 0.1);
}

.post-card.featured {
  border-left: 5px solid var(--coral);
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  color: var(--muted);
  font-size: 13px;
}

.post-meta span:first-child {
  color: var(--teal);
  font-weight: 800;
}

.post-card h3 {
  margin: 10px 0 8px;
  font-size: clamp(21px, 3vw, 29px);
  line-height: 1.25;
}

.post-card p {
  margin: 0 0 14px;
  color: var(--muted);
}

.post-card a {
  color: var(--teal);
  font-weight: 800;
}

.sidebar {
  display: grid;
  align-content: start;
  gap: 18px;
}

.profile-card,
.side-panel {
  padding: 22px;
}

.avatar {
  display: grid;
  width: 68px;
  height: 68px;
  place-items: center;
  margin-bottom: 14px;
  color: #fff;
  background: linear-gradient(135deg, var(--teal), var(--coral));
  border-radius: 50%;
  font-size: 26px;
  font-weight: 900;
}

.profile-card h2,
.side-panel h2 {
  margin: 0 0 10px;
  font-size: 21px;
}

.profile-card p {
  margin: 0;
  color: var(--muted);
}

.social-links a,
.tag-cloud a {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--teal-dark);
  font-size: 13px;
  font-weight: 800;
}

.category-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.category-list a {
  display: flex;
  justify-content: space-between;
  color: #3b444a;
}

.category-list span {
  color: var(--coral);
  font-weight: 800;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.split-section,
.contact-section {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 42px;
  padding: 58px 0;
  border-top: 1px solid var(--line);
}

.split-section p,
.contact-section p {
  color: var(--muted);
}

.timeline {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.timeline li {
  display: grid;
  gap: 4px;
  padding: 18px 20px;
  border-left: 4px solid var(--gold);
  border-radius: var(--radius);
  background: var(--surface-strong);
}

.timeline time {
  color: var(--teal-dark);
  font-weight: 900;
}

.timeline span {
  color: var(--muted);
}

.projects-section {
  padding: 32px 0 72px;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.project-card {
  min-height: 190px;
  padding: 22px;
}

.project-card span {
  color: var(--coral);
  font-weight: 900;
}

.project-card h3 {
  margin: 26px 0 8px;
  font-size: 22px;
}

.project-card p {
  margin: 0;
  color: var(--muted);
}

.contact-section {
  align-items: center;
  padding-bottom: 78px;
}

.subscribe-form {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 12px;
}

.form-note {
  grid-column: 1 / -1;
  min-height: 24px;
  margin: 0;
  color: var(--teal-dark);
  font-weight: 800;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 28px clamp(18px, 4vw, 54px);
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.site-footer p {
  margin: 0;
}

.hidden {
  display: none;
}

@media (max-width: 900px) {
  .nav-toggle {
    display: block;
  }

  .site-nav {
    position: absolute;
    top: 72px;
    right: 18px;
    display: none;
    width: min(260px, calc(100vw - 36px));
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface-strong);
    box-shadow: var(--shadow);
  }

  .site-nav.open {
    display: grid;
    gap: 4px;
  }

  .main-grid,
  .split-section,
  .contact-section {
    grid-template-columns: 1fr;
  }

  .project-grid,
  .stats-strip {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 620px) {
  .hero img {
    min-height: 610px;
  }

  .hero-overlay {
    background:
      linear-gradient(0deg, rgba(18, 24, 26, 0.9), rgba(18, 24, 26, 0.24)),
      linear-gradient(90deg, rgba(18, 24, 26, 0.62), rgba(18, 24, 26, 0.2));
  }

  .hero-content {
    top: auto;
    bottom: 44px;
    transform: none;
  }

  .stats-strip,
  .project-grid,
  .subscribe-form {
    grid-template-columns: 1fr;
  }

  .post-tools {
    align-items: stretch;
    flex-direction: column;
  }

  .site-footer {
    flex-direction: column;
  }
}
