:root {
  --bg: #fafaf8;
  --surface: #ffffff;
  --ink: #1d1d1f;
  --ink-light: #6e6e73;
  --ink-lighter: #86868b;
  --border: rgba(0, 0, 0, 0.08);
  --accent: #c41e24;
  --accent-hover: #a3181d;
  --muted: #f5f5f7;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
  --radius: 8px;
  --radius-sm: 8px;
  --max-width: 1080px;
  --header-h: 64px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

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

button {
  font-family: inherit;
}

/* Header */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: rgba(250, 250, 248, 0.78);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s ease, background 0.3s ease;
}

.header.is-scrolled {
  border-color: var(--border);
}

.header__inner {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: inline-flex;
  align-items: center;
}

.logo__img {
  height: 34px;
  width: auto;
  display: block;
}

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

.nav__link {
  padding: 8px 14px;
  font-size: 0.9rem;
  color: var(--ink-light);
  border-radius: 999px;
  transition: color 0.25s ease, background 0.25s ease;
}

.nav__link:hover,
.nav__link:focus-visible {
  color: var(--ink);
  background: rgba(0, 0, 0, 0.04);
}

.nav__link.is-active {
  color: var(--ink);
  background: rgba(0, 0, 0, 0.06);
}

.menu-btn {
  display: none;
  width: 40px;
  height: 40px;
  border: none;
  background: transparent;
  border-radius: 10px;
  cursor: pointer;
}

.menu-btn:hover {
  background: rgba(0, 0, 0, 0.04);
}

.menu-btn__icon {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--ink);
  margin: 0 auto;
  position: relative;
  transition: background 0.2s ease;
}

.menu-btn__icon::before,
.menu-btn__icon::after {
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--ink);
  transition: transform 0.25s var(--ease-out), top 0.25s var(--ease-out);
}

.menu-btn__icon::before { top: -6px; }
.menu-btn__icon::after { top: 6px; }

.menu-btn.is-open .menu-btn__icon { background: transparent; }
.menu-btn.is-open .menu-btn__icon::before { top: 0; transform: rotate(45deg); }
.menu-btn.is-open .menu-btn__icon::after { top: 0; transform: rotate(-45deg); }

/* Layout */
.page {
  padding-top: var(--header-h);
}

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

.section {
  padding: 88px 0;
}

.section--hero {
  padding: 120px 0 100px;
}

.section--intro {
  padding: 96px 0 84px;
}

.section--page-head {
  padding: 52px 0;
}

.section--muted {
  background: var(--muted);
}

.section-heading {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 28px;
}

.section-heading--spacious {
  margin-bottom: 56px;
}

.page-heading {
  text-align: center;
  max-width: 760px;
  margin: 0 auto;
}

.page-heading--left {
  text-align: left;
  margin: 0 0 48px;
}

.page-heading .body-lg {
  margin: 20px auto 0;
}

.page-heading--left .body-lg {
  margin-left: 0;
}

/* Typography */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 22px;
}

.eyebrow::before {
  content: "";
  width: 24px;
  height: 2px;
  background: currentColor;
}

.title-1 {
  font-size: 4rem;
  line-height: 1.08;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--ink);
}

.title-2 {
  font-size: 2.45rem;
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--ink);
}

.title-3 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 0;
}

.body-lg {
  font-size: 1.25rem;
  line-height: 1.7;
  color: var(--ink-light);
  max-width: 760px;
}

.body {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--ink-light);
}

.caption {
  font-size: 0.85rem;
  color: var(--ink-lighter);
}

/* Intro */
.intro-block {
  max-width: 880px;
}

.intro-block .body {
  margin-top: 28px;
}

.intro-block__body {
  margin-top: 28px;
}

/* Stats */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 70px;
}

.stats--compact {
  margin-top: 32px;
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.stat-card__num {
  font-size: 2.2rem;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--accent);
  line-height: 1.1;
}

.stat-card__label {
  margin-top: 10px;
  font-size: 0.95rem;
  color: var(--ink-light);
}

/* Profile */
.profile {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 64px;
  align-items: start;
}

.profile__text p + p {
  margin-top: 1.2em;
}

.profile__media {
  position: relative;
}

.profile__image {
  width: 100%;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* Cards grid */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.media-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
}

.media-grid--gallery {
  margin-top: 32px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}

.card__img {
  width: 100%;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--muted);
}

.media-grid .card__img {
  margin-bottom: 20px;
}

.media-grid--gallery .card__img {
  margin-bottom: 0;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
}

.card__icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(196, 30, 36, 0.08);
  color: var(--accent);
  display: grid;
  place-items: center;
  margin-bottom: 18px;
}

.card__title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.card__text {
  font-size: 0.98rem;
  color: var(--ink-light);
  line-height: 1.7;
}

/* Jobs */
.jobs-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.job-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.job-item__header {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 22px 28px;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  transition: background 0.2s ease;
}

.job-item__header:hover {
  background: rgba(0, 0, 0, 0.015);
}

.job-item__title {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0;
}

.job-item__meta {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-shrink: 0;
}

.job-item__tag {
  font-size: 0.8rem;
  padding: 5px 11px;
  border-radius: 999px;
  background: var(--muted);
  color: var(--ink-light);
  white-space: nowrap;
}

.job-item__arrow {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--muted);
  display: grid;
  place-items: center;
  transition: transform 0.35s var(--ease-out), background 0.2s ease;
  flex-shrink: 0;
}

.job-item.is-open .job-item__arrow {
  transform: rotate(180deg);
  background: rgba(196, 30, 36, 0.08);
}

.job-item__body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.4s var(--ease-out);
}

.job-item.is-open .job-item__body {
  grid-template-rows: 1fr;
}

.job-item__inner {
  overflow: hidden;
}

.job-item__content {
  padding: 0 28px 28px;
  color: var(--ink-light);
  line-height: 1.8;
}

.job-item__content h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ink);
  margin: 22px 0 10px;
}

.job-item__content h4:first-child {
  margin-top: 0;
}

.job-item__content ul {
  padding-left: 1.2em;
}

.job-item__content li + li {
  margin-top: 0.4em;
}

.job-item__contact {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  font-size: 0.92rem;
}

.job-item__contact span {
  color: var(--ink-lighter);
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 70px;
}

.contact-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 34px;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}

.contact-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
}

.contact-card__icon {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: rgba(196, 30, 36, 0.08);
  color: var(--accent);
  display: grid;
  place-items: center;
  margin: 0 auto 18px;
}

.contact-card__label {
  font-size: 0.85rem;
  color: var(--ink-lighter);
  margin-bottom: 6px;
}

.contact-card__value {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: 0;
}

.contact-card__value--email {
  font-size: 1.05rem;
}

.contact-card__value a:hover {
  color: var(--accent);
}

/* Contact */
.section--contact {
  padding-top: 104px;
}

.contact-panel {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 32px;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 34px;
  box-shadow: var(--shadow-sm);
}

.contact-panel__img,
.wide-image {
  width: 100%;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--muted);
}

.wide-image {
  margin-bottom: 36px;
}

/* Footer */
.footer {
  padding: 48px 0;
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.footer__copy {
  font-size: 0.85rem;
  color: var(--ink-lighter);
}

.footer__links {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
  font-size: 0.8rem;
  color: var(--ink-lighter);
}

.footer__img {
  display: inline-block;
  vertical-align: middle;
  margin-right: 6px;
}

.footer__links a:hover {
  color: var(--accent);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .job-item__body {
    transition: none;
  }
}

/* Focus */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Responsive */
@media (max-width: 900px) {
  .header__inner {
    padding: 0 20px;
  }
  .nav {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: rgba(250, 250, 248, 0.96);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    padding: 12px 20px 20px;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.35s var(--ease-out), opacity 0.3s ease;
  }
  .nav.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  .nav__link {
    padding: 14px 0;
    border-radius: 0;
    border-bottom: 1px solid var(--border);
  }
  .nav__link:last-child {
    border-bottom: none;
  }
  .menu-btn {
    display: grid;
    place-items: center;
  }
  .profile {
    grid-template-columns: 1fr;
    gap: 42px;
  }
  .grid-3,
  .media-grid,
  .stats,
  .contact-grid,
  .contact-panel {
    grid-template-columns: 1fr;
  }
  .section {
    padding: 80px 0;
  }
  .section--hero {
    padding: 90px 0 70px;
  }
  .title-1 {
    font-size: 3rem;
  }
  .title-2 {
    font-size: 2.1rem;
  }
  .page-heading--left {
    text-align: center;
    margin-left: auto;
    margin-right: auto;
  }
  .page-heading--left .body-lg {
    margin-left: auto;
  }
}

@media (max-width: 480px) {
  .wrap {
    padding: 0 18px;
  }
  .stat-card,
  .card,
  .contact-card,
  .contact-panel,
  .job-item {
    border-radius: var(--radius);
  }
  .title-1 {
    font-size: 2.35rem;
  }
  .title-2 {
    font-size: 1.8rem;
  }
  .body-lg {
    font-size: 1.05rem;
  }
  .contact-panel {
    padding: 22px;
  }
  .job-item__header {
    padding: 18px 20px;
  }
  .job-item__content {
    padding: 0 20px 22px;
  }
  .job-item__meta {
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
  }
}
