:root {
  --primary: #3b3833;
  --secondary: #f6efe8;
  --accent: #e3c1b6;
  --accent-2: #b9b89f;
  --text: #3b3833;
  --muted: #6b655e;
  --white: #ffffff;
  --shadow: 0 12px 30px rgba(67, 59, 52, 0.12);
  --radius: 14px;
  --max-width: 1140px;
  --hero-bg: #f1d6cf;
  --highlight-bg: #5b6470;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Source Han Sans SC", "思源黑体", "Noto Sans CJK SC", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: #fffaf6;
  line-height: 1.6;
}

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

img {
  width: 100%;
  display: block;
  border-radius: 16px;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 80px 0;
}

.section-title {
  margin-bottom: 36px;
}

.section-title h2 {
  margin: 0 0 8px;
  font-size: 28px;
  letter-spacing: 0.5px;
}

.section-title p {
  margin: 0;
  color: var(--muted);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: 6px;
  font-weight: 600;
  border: 1px solid transparent;
  transition: all 0.2s ease;
  cursor: pointer;
}

.btn.primary {
  background: var(--accent);
  color: var(--primary);
}

.btn.primary:hover {
  background: #d8b1a4;
}

.btn.secondary {
  background: var(--accent-2);
  color: var(--primary);
}

.btn.secondary:hover {
  background: #a6a58f;
  color: var(--primary);
}

.btn.ghost {
  border: 1px solid var(--accent);
  color: var(--primary);
}

.btn.ghost:hover {
  background: var(--primary);
  color: var(--white);
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 10px;
  background: var(--primary);
  color: var(--white);
  padding: 8px 12px;
  border-radius: 6px;
}

.skip-link:focus {
  left: 16px;
  z-index: 10;
}

.site-header {
  position: sticky;
  top: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px 0;
}

.brand {
  font-weight: 600;
  font-size: 15px;
  color: var(--primary);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 16px;
}

.nav-list {
  list-style: none;
  display: flex;
  gap: 20px;
  margin: 0;
  padding: 0;
}

.nav-overlay {
  display: none;
}

.nav-list a {
  font-size: 14px;
  color: var(--muted);
  position: relative;
  padding-bottom: 6px;
}

.nav-list a.active,
.nav-list a:hover {
  color: var(--primary);
  font-weight: 600;
}

.nav-list a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width 0.3s ease;
}

.nav-list a:hover::after,
.nav-list a.active::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  width: 40px;
  height: 40px;
  position: relative;
}

.nav-toggle__icon,
.nav-toggle__icon::before,
.nav-toggle__icon::after {
  position: absolute;
  left: 8px;
  right: 8px;
  height: 2px;
  background: var(--primary);
  content: "";
  transition: transform 0.3s ease;
}

.nav-toggle__icon {
  top: 50%;
}

.nav-toggle__icon::before {
  top: -8px;
}

.nav-toggle__icon::after {
  top: 8px;
}

.lang-toggle {
  border: 1px solid var(--accent);
  background: rgba(255, 255, 255, 0.7);
  color: var(--primary);
  border-radius: 16px;
  padding: 6px 14px;
  font-size: 13px;
  cursor: pointer;
}

.hero {
  background: var(--hero-bg);
}

.hero-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px;
  align-items: center;
}

.hero-title {
  font-size: 34px;
  margin: 12px 0 16px;
  line-height: 1.3;
  color: var(--primary);
}

.hero-subtitle {
  margin: 0 0 24px;
  color: var(--muted);
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-meta {
  margin-top: 20px;
  color: var(--muted);
  font-size: 14px;
}

.eyebrow {
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 2px;
  color: var(--muted);
}

.carousel {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

.carousel-item {
  display: none;
}

.carousel-item.active {
  display: block;
}

.carousel-dots {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
}

.carousel-dots button {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 255, 255, 0.6);
  cursor: pointer;
}

.carousel-dots button.active {
  background: var(--accent);
}

.photo-note {
  font-size: 13px;
  color: var(--muted);
  margin-top: 12px;
}

.about {
  background: #ffffff;
}

.about-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px;
  align-items: center;
}

.about-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-top: 24px;
}

.education-cards {
  display: grid;
  gap: 12px;
}

.education-card {
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--secondary);
  color: var(--muted);
}

.education-card strong {
  color: var(--primary);
  display: block;
  margin-bottom: 4px;
}

.education {
  background: var(--secondary);
}

.card {
  background: #f4ece6;
  padding: 18px;
  border-radius: var(--radius);
  border: 1px solid rgba(89, 78, 70, 0.08);
}

.card h3 {
  margin: 0 0 8px;
  font-size: 16px;
  color: var(--primary);
}

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

.highlights {
  background: var(--highlight-bg);
  color: var(--white);
}

.highlights .section-title h2,
.highlights .section-title p {
  color: var(--white);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
}

.stat-card {
  background: rgba(255, 255, 255, 0.1);
  padding: 24px;
  border-radius: var(--radius);
  transition: transform 0.2s ease;
}

.stat-card:hover {
  transform: translateY(-5px);
}

.stat-card h3 {
  margin: 0;
  font-size: 26px;
}

.stat-card p {
  margin: 8px 0 0;
  color: var(--secondary);
  font-size: 14px;
}

.experience {
  background: #ffffff;
}

.filters {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}

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

.filter-btn {
  border: 1px solid var(--accent);
  background: transparent;
  padding: 8px 16px;
  border-radius: 20px;
  cursor: pointer;
  font-size: 13px;
  color: var(--primary);
}

.filter-btn.active,
.filter-btn:hover {
  background: var(--primary);
  color: var(--white);
}

.filter-select {
  display: none;
}

.filter-select select {
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid var(--accent);
}

.timeline {
  border-left: 2px solid var(--accent);
  padding-left: 24px;
  display: grid;
  gap: 24px;
}

.timeline-item {
  position: relative;
  padding: 18px 20px;
  border-radius: var(--radius);
  background: var(--secondary);
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -34px;
  top: 28px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
}

.timeline-item h3 {
  margin: 0;
  font-size: 16px;
  color: var(--primary);
}

.timeline-item .meta {
  font-size: 13px;
  color: var(--muted);
  margin: 4px 0 12px;
}

.timeline-item ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 14px;
}

.projects {
  background: #f7f0e9;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.project-card {
  background: #fffaf6;
  padding: 20px;
  border-radius: var(--radius);
  box-shadow: 0 8px 24px rgba(83, 73, 66, 0.08);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.project-card img {
  border-radius: 12px;
  height: 180px;
  object-fit: cover;
}

.project-card h3 {
  margin: 0;
  color: var(--primary);
  font-size: 16px;
}

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

.skills {
  background: #fffaf6;
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px;
}

.skill-block {
  margin-bottom: 28px;
}

.skill-block h3 {
  margin: 0 0 12px;
  color: var(--primary);
}

.skill-bar {
  margin-bottom: 12px;
}

.skill-bar label {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 6px;
}

.progress {
  background: #f1e7df;
  border-radius: 10px;
  overflow: hidden;
  height: 10px;
}

.progress span {
  display: block;
  height: 100%;
  background: var(--accent-2);
}

.tag-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tag-list li {
  background: #f1e7df;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 13px;
  color: var(--primary);
}

.language-list {
  display: grid;
  gap: 12px;
}

.language-card {
  padding: 12px;
  border-radius: 12px;
  background: #f1e7df;
  color: var(--muted);
}

.gallery {
  background: #f7f0e9;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.gallery-grid img {
  height: 220px;
  object-fit: cover;
}

.contact {
  background: #fffaf6;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px;
}

.contact-form form {
  display: grid;
  gap: 16px;
}

.form-row {
  display: grid;
  gap: 8px;
}

.form-row input,
.form-row textarea,
.form-row select {
  border: 1px solid var(--accent);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 14px;
  font-family: inherit;
}

.form-status {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.contact-info {
  display: grid;
  gap: 20px;
}

.contact-card {
  background: #f4ece6;
  padding: 20px;
  border-radius: var(--radius);
}

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

.contact-card ul {
  list-style: none;
  padding: 0;
  margin: 0 0 16px;
  color: var(--muted);
}

.contact-card li {
  margin-bottom: 8px;
}

.contact-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.contact-tags span {
  background: #fffaf6;
  padding: 6px 12px;
  border-radius: 16px;
  font-size: 13px;
  color: var(--primary);
}

.site-footer {
  background: #f4ece6;
  padding: 24px 0;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-size: 13px;
  color: var(--muted);
}

.footer-links a {
  color: var(--primary);
  font-weight: 600;
}

.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
}

.modal.show {
  display: flex;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
}

.modal-content {
  position: relative;
  background: var(--white);
  padding: 24px;
  border-radius: var(--radius);
  max-width: 640px;
  max-height: 80vh;
  overflow-y: auto;
  z-index: 1;
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 16px;
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
}

@media (max-width: 980px) {
  .hero-grid,
  .about-grid,
  .skills-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .cards-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

@media (max-width: 768px) {
  .nav-list {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 240px;
    background: var(--white);
    flex-direction: column;
    padding: 80px 20px 20px;
    border-radius: 0 16px 16px 0;
    box-shadow: var(--shadow);
    transform: translateX(-110%);
    transition: transform 0.3s ease;
  }

  .nav-list.open {
    transform: translateX(0);
  }

  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .filters {
    flex-direction: column;
    align-items: flex-start;
  }

  .filter-tabs {
    display: none;
  }

  .filter-select {
    display: block;
  }

  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .cards-grid {
    grid-template-columns: 1fr;
  }

  .nav-overlay {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.2);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
  }

  .nav-overlay.show {
    opacity: 1;
    pointer-events: auto;
  }
}

@media (max-width: 600px) {
  .section {
    padding: 64px 0;
  }

  .hero-title {
    font-size: 26px;
  }

  .header-inner {
    flex-wrap: wrap;
  }

  .about-cards {
    grid-template-columns: 1fr;
  }
}
