:root {
  --ink: #171717;
  --muted: #5f625d;
  --paper: #f7f7f0;
  --surface: #ffffff;
  --line: #d9ded5;
  --coral: #df5b3f;
  --teal: #237a73;
  --gold: #c69219;
  --violet: #6f5aa8;
  --shadow: 0 24px 70px rgba(23, 23, 23, 0.12);
  --radius: 8px;
  --speed: 180ms;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  overflow-x: hidden;
  font-family: "Inter", "Noto Sans SC", system-ui, sans-serif;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(35, 122, 115, 0.07) 1px, transparent 1px),
    linear-gradient(180deg, rgba(223, 91, 63, 0.07) 1px, transparent 1px),
    var(--paper);
  background-size: 42px 42px;
}

body::selection {
  color: var(--surface);
  background: var(--teal);
}

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

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid rgba(223, 91, 63, 0.42);
  outline-offset: 4px;
}

.progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 100;
  width: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--coral), var(--teal), var(--gold));
}

.site-header {
  position: fixed;
  top: 18px;
  left: 50%;
  z-index: 50;
  display: grid;
  grid-template-columns: 1fr auto 44px;
  align-items: center;
  width: min(1120px, calc(100% - 32px));
  min-height: 56px;
  padding: 8px 8px 8px 14px;
  border: 1px solid rgba(23, 23, 23, 0.12);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 16px 50px rgba(23, 23, 23, 0.08);
  backdrop-filter: blur(16px);
  transform: translateX(-50%);
}

.brand,
.nav-links,
.hero-actions,
.project-top,
.contact-item,
.footer,
.text-link {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  color: var(--surface);
  background: var(--ink);
  border-radius: 6px;
}

.nav-links {
  gap: 4px;
  padding: 3px;
  border: 1px solid rgba(23, 23, 23, 0.1);
  border-radius: 6px;
  background: rgba(247, 247, 240, 0.86);
}

.nav-links a {
  min-height: 34px;
  padding: 8px 13px;
  border-radius: 5px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
  transition: color var(--speed) ease, background var(--speed) ease;
}

.nav-links a:hover {
  color: var(--ink);
  background: var(--surface);
}

.icon-button,
.action-link,
.project-top a {
  display: inline-grid;
  place-items: center;
}

.icon-button {
  justify-self: end;
  width: 40px;
  height: 40px;
  border-radius: 6px;
  color: var(--surface);
  background: var(--teal);
  transition: transform var(--speed) ease, background var(--speed) ease;
}

.icon-button:hover {
  background: var(--coral);
  transform: translateY(-1px);
}

.icon-button svg,
.action-link svg,
.text-link svg,
.project-top svg,
.focus-card svg,
.contact-item svg {
  width: 18px;
  height: 18px;
  stroke-width: 2.1;
}

.hero {
  position: relative;
  display: grid;
  align-items: end;
  min-height: 92vh;
  padding: 136px min(7vw, 88px) 54px;
  overflow: hidden;
  isolation: isolate;
  background:
    linear-gradient(120deg, rgba(247, 247, 240, 0.96) 0%, rgba(247, 247, 240, 0.9) 43%, rgba(247, 247, 240, 0.58) 74%, rgba(247, 247, 240, 0.28) 100%),
    radial-gradient(circle at 20% 30%, rgba(198, 146, 25, 0.18), transparent 30%),
    linear-gradient(135deg, rgba(35, 122, 115, 0.18), rgba(223, 91, 63, 0.16));
}

.hero::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 24px;
  content: "";
  background: repeating-linear-gradient(90deg, var(--ink) 0 18px, var(--coral) 18px 36px, var(--teal) 36px 54px, var(--gold) 54px 72px);
}

.hero-portrait {
  position: absolute;
  top: 88px;
  right: min(6vw, 72px);
  z-index: -2;
  width: min(48vw, 560px);
  min-width: 320px;
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid rgba(23, 23, 23, 0.18);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  filter: saturate(0.94) contrast(1.06);
  transform: rotate(2deg);
}

.hero-grid {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(23, 23, 23, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(23, 23, 23, 0.08) 1px, transparent 1px);
  background-size: 68px 68px;
  mask-image: linear-gradient(90deg, #000 0%, #000 58%, transparent 94%);
}

.hero-content {
  width: min(820px, 100%);
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--teal);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 820px;
  margin-bottom: 22px;
  font-size: 8.5rem;
  line-height: 0.92;
  letter-spacing: 0;
}

h1 span {
  display: inline-block;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 2px var(--ink);
}

.hero-copy {
  max-width: 610px;
  margin-bottom: 28px;
  color: #31332f;
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.7;
}

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

.action-link {
  grid-auto-flow: column;
  gap: 8px;
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid rgba(23, 23, 23, 0.16);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.74);
  font-weight: 800;
  transition: transform var(--speed) ease, border-color var(--speed) ease, background var(--speed) ease;
}

.action-link:hover {
  border-color: rgba(23, 23, 23, 0.28);
  background: var(--surface);
  transform: translateY(-2px);
}

.action-link.primary {
  color: var(--surface);
  border-color: var(--ink);
  background: var(--ink);
}

.hero-notes {
  position: absolute;
  right: min(7vw, 88px);
  bottom: 58px;
  display: grid;
  width: min(320px, 38vw);
  border: 1px solid rgba(23, 23, 23, 0.14);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 18px 54px rgba(23, 23, 23, 0.1);
  backdrop-filter: blur(12px);
}

.hero-notes div {
  display: grid;
  gap: 3px;
  padding: 16px 18px;
  border-bottom: 1px solid rgba(23, 23, 23, 0.12);
}

.hero-notes div:last-child {
  border-bottom: 0;
}

.hero-notes span {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero-notes strong {
  font-size: 1.05rem;
}

.section {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 86px 0;
}

.intro-band,
.achievement-band {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 28px;
  align-items: start;
  border-bottom: 1px solid rgba(23, 23, 23, 0.14);
}

.section-label {
  color: var(--coral);
  font-size: 0.8rem;
  font-weight: 800;
  text-transform: uppercase;
}

.intro-text p {
  max-width: 900px;
  margin-bottom: 22px;
  font-size: 3rem;
  font-weight: 800;
  line-height: 1.14;
  letter-spacing: 0;
}

.intro-meta {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.intro-meta span,
.tags span {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  padding: 0 10px;
  border: 1px solid rgba(23, 23, 23, 0.13);
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.7);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.section-heading {
  max-width: 740px;
  margin-bottom: 30px;
}

.section-heading.split {
  display: flex;
  max-width: none;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
}

h2 {
  margin-bottom: 0;
  font-size: 4.5rem;
  line-height: 1;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 10px;
  font-size: 1.25rem;
  letter-spacing: 0;
}

.focus-grid,
.project-grid,
.contact-grid {
  display: grid;
  gap: 16px;
}

.focus-grid {
  grid-template-columns: repeat(3, 1fr);
}

.focus-card,
.project-card {
  position: relative;
  min-height: 250px;
  padding: 22px;
  overflow: hidden;
  border: 1px solid rgba(23, 23, 23, 0.13);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 18px 48px rgba(23, 23, 23, 0.07);
}

.focus-card::before,
.project-card::before {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 7px;
  content: "";
  background: var(--teal);
}

.focus-card:nth-child(2)::before {
  background: var(--coral);
}

.focus-card:nth-child(3)::before {
  background: var(--gold);
}

.focus-card svg {
  width: 34px;
  height: 34px;
  margin-bottom: 54px;
  color: var(--teal);
}

.focus-card:nth-child(2) svg {
  color: var(--coral);
}

.focus-card:nth-child(3) svg {
  color: var(--gold);
}

.focus-card p,
.project-card p,
.timeline-body p,
.achievement-band p {
  color: var(--muted);
  line-height: 1.7;
}

.research-section {
  width: 100%;
  max-width: none;
  padding-right: max(16px, calc((100vw - 1120px) / 2));
  padding-left: max(16px, calc((100vw - 1120px) / 2));
  background:
    linear-gradient(180deg, rgba(23, 23, 23, 0.97), rgba(28, 29, 27, 0.95)),
    var(--ink);
  color: var(--surface);
}

.research-section .eyebrow {
  color: #f0ad54;
}

.timeline {
  display: grid;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
}

.timeline-item {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 28px;
  padding: 28px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
}

.timeline-date {
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.86rem;
  font-weight: 800;
}

.timeline-body {
  max-width: 820px;
}

.timeline-body h3 {
  font-size: 2.25rem;
}

.timeline-body .subtitle {
  margin-bottom: 8px;
  color: #f0ad54;
  font-weight: 800;
}

.timeline-body p:last-child {
  color: rgba(255, 255, 255, 0.72);
}

.text-link {
  gap: 8px;
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid rgba(23, 23, 23, 0.13);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.78);
  color: var(--muted);
  font-weight: 800;
}

.text-link:hover {
  color: var(--ink);
  border-color: rgba(23, 23, 23, 0.24);
}

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

.project-card {
  min-height: 270px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.project-top {
  justify-content: space-between;
  gap: 20px;
}

.project-top a {
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(23, 23, 23, 0.14);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.8);
  transition: transform var(--speed) ease, border-color var(--speed) ease;
}

.project-top a:hover {
  border-color: rgba(23, 23, 23, 0.3);
  transform: translateY(-2px);
}

.accent-a::before {
  background: var(--teal);
}

.accent-b::before {
  background: var(--coral);
}

.accent-c::before {
  background: var(--violet);
}

.accent-d::before {
  background: var(--gold);
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.achievement-band {
  grid-template-columns: 340px 1fr;
  align-items: center;
  padding: 52px 0;
  border-top: 1px solid rgba(23, 23, 23, 0.14);
}

.achievement-band h2 {
  color: var(--coral);
}

.achievement-band p {
  max-width: 720px;
  margin-bottom: 0;
  font-size: 1.05rem;
}

.contact-section {
  padding-top: 72px;
}

.contact-grid {
  grid-template-columns: repeat(3, 1fr);
}

.contact-item {
  gap: 12px;
  min-height: 74px;
  padding: 18px;
  border: 1px solid rgba(23, 23, 23, 0.13);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.78);
  font-weight: 800;
  transition: transform var(--speed) ease, border-color var(--speed) ease, background var(--speed) ease;
}

.contact-item:hover {
  border-color: rgba(23, 23, 23, 0.26);
  background: var(--surface);
  transform: translateY(-2px);
}

.contact-item svg {
  flex: 0 0 auto;
  color: var(--coral);
}

.contact-item span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.footer {
  justify-content: space-between;
  width: min(1120px, calc(100% - 32px));
  min-height: 74px;
  margin: 0 auto;
  padding: 22px 0 34px;
  border-top: 1px solid rgba(23, 23, 23, 0.14);
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

@media (max-width: 980px) {
  .site-header {
    grid-template-columns: 1fr 44px;
  }

  .icon-button {
    grid-column: 2;
  }

  .nav-links {
    display: none;
  }

  .hero {
    min-height: 900px;
    padding: 122px 24px 42px;
  }

  .hero-portrait {
    top: 112px;
    right: 20px;
    width: min(78vw, 430px);
    opacity: 0.32;
  }

  .hero-notes {
    position: relative;
    right: auto;
    bottom: auto;
    width: min(100%, 460px);
    margin-top: 32px;
  }

  .section,
  .footer {
    width: min(100% - 28px, 760px);
  }

  h1 {
    font-size: 6.15rem;
  }

  h2 {
    font-size: 3.35rem;
  }

  .hero-copy {
    font-size: 1.08rem;
  }

  .intro-text p {
    font-size: 2.2rem;
  }

  .timeline-body h3 {
    font-size: 1.7rem;
  }

  .intro-band,
  .achievement-band,
  .timeline-item {
    grid-template-columns: 1fr;
  }

  .intro-meta {
    grid-column: auto;
  }

  .focus-grid,
  .project-grid,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .section-heading.split {
    align-items: start;
    flex-direction: column;
  }
}

@media (max-width: 560px) {
  .site-header {
    top: 10px;
    right: 10px;
    left: 10px;
    width: auto;
    grid-template-columns: 44px 1fr 44px;
    transform: none;
  }

  .brand {
    grid-column: 1;
  }

  .icon-button {
    grid-column: 3;
  }

  .brand span:last-child {
    display: none;
  }

  .hero {
    min-height: 820px;
    padding: 104px 18px 38px;
  }

  .hero-portrait {
    top: 86px;
    right: -70px;
    min-width: 300px;
    opacity: 0.24;
  }

  h1 {
    font-size: 3.72rem;
  }

  h1 span {
    -webkit-text-stroke: 1.4px var(--ink);
  }

  .hero-copy {
    font-size: 1rem;
    max-width: 330px;
    overflow-wrap: anywhere;
  }

  .action-link {
    width: 100%;
    justify-content: center;
  }

  .section {
    padding: 58px 0;
  }

  .intro-text p {
    font-size: 1.65rem;
  }

  h2 {
    font-size: 2.35rem;
  }

  .focus-card,
  .project-card {
    min-height: auto;
  }

  .focus-card svg {
    margin-bottom: 34px;
  }

  .contact-item {
    min-height: 66px;
  }

  .footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
