:root {
  color-scheme: light;
  --ink: #111111;
  --muted: #4e4b45;
  --paper: #fff8ea;
  --bg: #ece8dd;
  --green: #00a978;
  --green-dark: #027052;
  --yellow: #ffd426;
  --blue: #2c8df0;
  --orange: #ff7b3d;
  --line: #111111;
  --nav-height: 72px;
  --shadow: 8px 8px 0 #111111;
  --soft-shadow: 0 16px 34px rgba(17, 17, 17, 0.14);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: "Arial Rounded MT Bold", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  background:
    linear-gradient(90deg, rgba(17, 17, 17, 0.045) 1px, transparent 1px),
    linear-gradient(180deg, rgba(17, 17, 17, 0.045) 1px, transparent 1px),
    var(--bg);
  background-size: 36px 36px;
  line-height: 1.6;
}

body.modal-open {
  overflow: hidden;
}

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

button {
  font: inherit;
}

img {
  max-width: 100%;
}

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

.site-header {
  position: fixed;
  top: 0;
  left: 50%;
  z-index: 50;
  width: min(1180px, calc(100% - 28px));
  height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 0 clamp(16px, 4vw, 34px);
  border: 3px solid var(--line);
  border-top: 0;
  border-radius: 0 0 18px 18px;
  background: rgba(255, 248, 234, 0.94);
  box-shadow: 0 8px 0 rgba(17, 17, 17, 0.08);
  transform: translateX(-50%);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.site-header.is-scrolled {
  box-shadow: 0 10px 0 rgba(17, 17, 17, 0.16);
  transform: translateX(-50%) translateY(-2px);
}

.brand {
  min-width: max-content;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
}

.brand span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 38px;
  border: 3px solid var(--line);
  border-radius: 12px;
  background: var(--yellow);
  box-shadow: 4px 4px 0 var(--line);
  font-size: 20px;
}

.brand strong {
  font-size: 13px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(10px, 2.4vw, 24px);
  font-size: 13px;
  font-weight: 900;
}

.nav-links a {
  position: relative;
  padding: 8px 0;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 3px;
  height: 5px;
  border-radius: 999px;
  background: var(--yellow);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 170ms ease;
  z-index: -1;
}

.nav-links a:hover::after,
.nav-links a:focus-visible::after,
.nav-links a.is-active::after {
  transform: scaleX(1);
}

.section,
.detail-main {
  width: min(1180px, calc(100% - 28px));
  scroll-margin-top: calc(var(--nav-height) + 22px);
  margin: 0 auto;
  padding: clamp(54px, 8vw, 92px) clamp(18px, 5vw, 54px);
  border-left: 3px solid var(--line);
  border-right: 3px solid var(--line);
  background: var(--paper);
}

.hero-section {
  min-height: auto;
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(320px, 0.92fr);
  gap: clamp(26px, 5vw, 62px);
  align-items: center;
  padding-top: calc(var(--nav-height) + clamp(54px, 8vw, 94px));
  padding-bottom: clamp(38px, 5vw, 60px);
  border-top: 3px solid var(--line);
}

.hero-copy {
  position: relative;
}

.hero-copy::before,
.hero-copy::after {
  content: "*";
  position: absolute;
  color: var(--ink);
  font-size: 44px;
  font-weight: 900;
  line-height: 1;
}

.hero-copy::before {
  top: -38px;
  right: 16%;
}

.hero-copy::after {
  right: 4%;
  bottom: -34px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  margin-bottom: 18px;
  padding: 0 16px;
  border: 3px solid var(--line);
  border-radius: 999px;
  background: #ffffff;
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

h1 {
  max-width: 780px;
  margin-bottom: 22px;
  font-size: clamp(42px, 6.4vw, 78px);
  line-height: 0.98;
  letter-spacing: 0;
  text-transform: none;
}

.hero-copy h1 {
  max-width: 680px;
  font-size: clamp(38px, 5.2vw, 64px);
  line-height: 1.08;
}

.hero-copy h1 span {
  display: block;
}

.hero-lede {
  max-width: 760px;
  color: var(--muted);
  font-size: clamp(16px, 1.6vw, 20px);
  font-weight: 700;
}

.hero-actions,
.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border: 3px solid var(--line);
  border-radius: 10px;
  background: #ffffff;
  color: var(--ink);
  cursor: pointer;
  font-size: 14px;
  font-weight: 900;
  box-shadow: 4px 4px 0 var(--line);
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.button:hover,
.button:focus-visible {
  background: var(--yellow);
  transform: translate(-2px, -2px);
  box-shadow: 7px 7px 0 var(--line);
}

.primary-button {
  background: var(--green);
  color: #ffffff;
}

.primary-button:hover,
.primary-button:focus-visible {
  background: var(--green-dark);
  color: #ffffff;
}

.site-footer {
  width: min(1180px, calc(100% - 28px));
  margin: 0 auto;
  padding: 18px clamp(18px, 5vw, 54px) 28px;
  border-right: 3px solid var(--line);
  border-left: 3px solid var(--line);
  background: var(--paper);
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
}

.site-footer a {
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.site-footer a:hover,
.site-footer a:focus-visible {
  color: var(--ink);
}

.life-collage {
  position: relative;
  height: clamp(300px, 29vw, 374px);
  align-self: center;
  overflow: hidden;
  border: 3px solid var(--line);
  border-radius: 22px;
  background:
    linear-gradient(90deg, rgba(17, 17, 17, 0.055) 1px, transparent 1px),
    linear-gradient(180deg, rgba(17, 17, 17, 0.055) 1px, transparent 1px),
    #fffdf5;
  background-size: 22px 22px;
  box-shadow: var(--shadow);
}

.life-collage::before,
.life-collage::after {
  content: "";
  position: absolute;
  z-index: 3;
  border: 3px solid var(--line);
  pointer-events: none;
}

.life-collage::before {
  top: 16px;
  right: 18px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--yellow);
  box-shadow: 4px 4px 0 var(--line);
}

.life-collage::after {
  left: 18px;
  bottom: 16px;
  width: 72px;
  height: 22px;
  border-radius: 999px;
  background: var(--green);
  transform: rotate(-5deg);
}

.life-photo {
  position: relative;
  margin: 0;
  overflow: hidden;
  border: 3px solid var(--line);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 6px 6px 0 var(--line);
  transform: rotate(var(--tilt, 0deg));
  transition: transform 180ms ease, box-shadow 180ms ease, z-index 180ms ease;
}

.life-photo:hover {
  z-index: 4;
  transform: rotate(0deg) scale(1.035);
  box-shadow: 10px 10px 0 var(--line);
}

.life-photo img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.life-photo-1 {
  position: absolute;
  left: 5%;
  top: 8%;
  z-index: 2;
  width: 34%;
  height: 56%;
  --tilt: -2deg;
}

.life-photo-2 {
  position: absolute;
  left: 35%;
  top: 5%;
  z-index: 1;
  width: 29%;
  height: 38%;
  --tilt: 1.5deg;
}

.life-photo-3 {
  position: absolute;
  right: 5%;
  top: 14%;
  z-index: 2;
  width: 31%;
  height: 54%;
  --tilt: 2deg;
}

.life-photo-4 {
  position: absolute;
  left: 18%;
  bottom: 7%;
  z-index: 2;
  width: 28%;
  height: 32%;
  --tilt: -1deg;
}

.life-photo-5 {
  position: absolute;
  left: 50%;
  bottom: 8%;
  z-index: 2;
  width: 24%;
  height: 43%;
  --tilt: 1deg;
}

.life-photo-6 {
  position: absolute;
  left: 5%;
  bottom: 11%;
  z-index: 1;
  width: 18%;
  height: 30%;
  --tilt: -1.5deg;
}

.life-photo-7 {
  position: absolute;
  right: 8%;
  bottom: 7%;
  z-index: 3;
  width: 21%;
  height: 31%;
  --tilt: -2deg;
}

.life-photo-8 {
  position: absolute;
  left: 38%;
  top: 38%;
  z-index: 3;
  width: 20%;
  height: 29%;
  --tilt: -1deg;
}

.life-photo-9 {
  position: absolute;
  right: 27%;
  bottom: 6%;
  z-index: 1;
  width: 19%;
  height: 31%;
  --tilt: 1.5deg;
}

.metric-row,
.capability-grid {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.metric-row div,
.capability-grid article {
  min-height: 128px;
  padding: 20px;
  border: 3px solid var(--line);
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 5px 5px 0 var(--line);
}

.metric-row div:nth-child(2),
.capability-grid article:nth-child(2) {
  background: #e8f7ff;
}

.metric-row div:nth-child(3),
.capability-grid article:nth-child(3) {
  background: #fff2a8;
}

.metric-row div:nth-child(4),
.capability-grid article:nth-child(4) {
  background: #e5f8ef;
}

.metric-row strong {
  display: block;
  margin-bottom: 8px;
  color: var(--green-dark);
  font-size: clamp(28px, 3.4vw, 44px);
  line-height: 1;
  text-shadow: 2px 2px 0 var(--yellow);
}

.metric-row span,
.capability-grid p {
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.capability-grid span {
  display: inline-flex;
  margin-bottom: 12px;
  padding: 4px 12px;
  border: 3px solid var(--line);
  border-radius: 999px;
  background: var(--green);
  color: #ffffff;
  font-size: 15px;
  font-weight: 900;
}

.capability-grid p {
  margin-bottom: 0;
}

.section-heading {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  max-width: 900px;
  margin-bottom: 34px;
}

.hero-copy,
.contact-card > div:first-child,
.detail-hero > div {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.section-heading h2,
.contact-card h2,
.project-detail h2 {
  display: inline-flex;
  margin-bottom: 16px;
  padding: 6px 22px;
  border: 3px solid var(--line);
  border-radius: 12px;
  background: var(--green);
  color: #ffffff;
  box-shadow: 5px 5px 0 var(--line);
  font-size: clamp(28px, 4vw, 48px);
  line-height: 1.12;
}

.section-heading p,
.contact-card p {
  color: var(--muted);
  font-size: 17px;
  font-weight: 700;
}

.projects-section {
  background:
    radial-gradient(circle at 12% 8%, rgba(255, 212, 38, 0.28), transparent 18%),
    var(--paper);
}

.timeline-list {
  position: relative;
  display: grid;
  gap: 0;
}

.timeline-list::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 190px;
  width: 4px;
  border-radius: 999px;
  background: var(--line);
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 160px 58px minmax(0, 1fr);
  gap: 0;
  padding: 0 0 22px;
}

.timeline-date {
  padding-top: 24px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 900;
}

.timeline-node {
  position: relative;
  display: block;
}

.timeline-node::before {
  content: "";
  position: absolute;
  top: 27px;
  left: 17px;
  width: 22px;
  height: 22px;
  border: 4px solid var(--line);
  border-radius: 50%;
  background: var(--yellow);
  transition: transform 180ms ease, background 180ms ease;
}

.timeline-content {
  display: grid;
  grid-template-columns: 158px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  padding: 18px;
  border: 3px solid var(--line);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 6px 6px 0 var(--line);
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.timeline-item:hover .timeline-node::before,
.timeline-item:focus-visible .timeline-node::before {
  background: var(--orange);
  transform: scale(1.18);
}

.timeline-item:hover .timeline-content,
.timeline-item:focus-visible .timeline-content {
  background: #fffdf5;
  box-shadow: 10px 10px 0 var(--line);
  transform: translate(-2px, -4px) scale(1.018);
}

.timeline-content img {
  width: 100%;
  display: block;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border: 3px solid var(--line);
  border-radius: 12px;
  background: #ffffff;
}

.timeline-copy {
  display: grid;
  gap: 8px;
}

.timeline-content strong {
  font-size: 22px;
  line-height: 1.25;
}

.timeline-content em {
  color: var(--green-dark);
  font-style: normal;
  font-weight: 900;
}

.timeline-content small {
  color: var(--muted);
  font-size: 15px;
  font-weight: 700;
}

.works-section {
  background: #fff5dc;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 28px;
}

.filter-bar button {
  min-height: 40px;
  padding: 0 16px;
  border: 3px solid var(--line);
  border-radius: 999px;
  background: #ffffff;
  color: var(--ink);
  cursor: pointer;
  font-size: 13px;
  font-weight: 900;
  box-shadow: 3px 3px 0 var(--line);
  transition: transform 150ms ease, background 150ms ease;
}

.filter-bar button:hover,
.filter-bar button:focus-visible {
  transform: translate(-1px, -1px);
}

.filter-bar button[aria-selected="true"] {
  background: var(--blue);
  color: #ffffff;
}

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

.work-card {
  position: relative;
  min-width: 0;
  display: grid;
  grid-template-rows: auto 1fr;
  overflow: hidden;
  border: 3px solid var(--line);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 6px 6px 0 var(--line);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

button.work-card {
  width: 100%;
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.work-card:hover,
.work-card:focus-visible {
  box-shadow: 10px 10px 0 var(--line);
  transform: translate(-2px, -4px) scale(1.018);
}

.work-card > img {
  width: 100%;
  display: block;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #ffffff;
}

.work-category {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 5px 10px;
  border: 3px solid var(--line);
  border-radius: 999px;
  background: var(--yellow);
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
}

.work-body {
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 18px;
  border-top: 3px solid var(--line);
}

.work-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.work-body h3 {
  min-height: 56px;
  margin-bottom: 0;
  font-size: 21px;
  line-height: 1.32;
}

.work-body p {
  margin-bottom: 0;
  color: var(--muted);
  font-weight: 700;
}

.work-body strong {
  color: var(--green-dark);
  line-height: 1.45;
}

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

.tag-list span {
  padding: 5px 9px;
  border: 2px solid var(--line);
  border-radius: 999px;
  background: #e8f7ff;
  color: var(--ink);
  font-size: 12px;
  font-weight: 900;
}

.work-empty {
  grid-column: 1 / -1;
}

.contact-section {
  border-bottom: 3px solid var(--line);
  background: var(--paper);
}

.contact-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: clamp(26px, 4vw, 44px);
  border: 3px solid var(--line);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.contact-card > div:first-child {
  max-width: 700px;
}

.contact-actions {
  justify-content: flex-end;
  margin-top: 0;
}

.contact-modal[hidden],
.work-modal[hidden] {
  display: none;
}

.contact-modal,
.work-modal {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(17, 17, 17, 0.56);
  animation: fade-in 160ms ease both;
}

.modal-panel {
  position: relative;
  width: min(560px, 100%);
  padding: 30px;
  border: 3px solid var(--line);
  border-radius: 22px;
  background: var(--paper);
  box-shadow: var(--shadow);
  animation: pop-in 190ms ease both;
}

.work-modal-panel {
  width: min(980px, 100%);
  max-height: min(86vh, 860px);
  overflow: auto;
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 38px;
  height: 38px;
  border: 3px solid var(--line);
  border-radius: 50%;
  background: var(--yellow);
  color: var(--ink);
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
}

.contact-modal-panel h2 {
  margin-bottom: 22px;
  font-size: 34px;
}

.work-modal-content h2 {
  margin-bottom: 12px;
  padding-right: 38px;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.12;
}

.work-modal-content > p {
  color: var(--muted);
  font-size: 16px;
  font-weight: 800;
}

.evidence-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 22px 0;
}

.evidence-metrics div {
  min-height: 96px;
  padding: 14px;
  border: 3px solid var(--line);
  border-radius: 14px;
  background: #fff2a8;
  box-shadow: 4px 4px 0 var(--line);
}

.evidence-metrics span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.evidence-metrics strong {
  display: block;
  margin-top: 6px;
  color: var(--green-dark);
  font-size: 24px;
  line-height: 1.15;
}

.evidence-chart {
  display: grid;
  gap: 12px;
  margin: 0 0 22px;
  padding: 18px;
  border: 3px solid var(--line);
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 4px 4px 0 var(--line);
}

.evidence-chart h3 {
  margin: 0;
  font-size: 18px;
}

.chart-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) 64px;
  gap: 12px;
  align-items: center;
  font-weight: 900;
}

.chart-row span {
  color: var(--muted);
  font-size: 13px;
}

.chart-row i {
  position: relative;
  height: 14px;
  overflow: hidden;
  border: 2px solid var(--line);
  border-radius: 999px;
  background: #fff5dc;
}

.chart-row i::before {
  content: "";
  position: absolute;
  inset: 0;
  width: var(--bar);
  border-right: 2px solid var(--line);
  background: linear-gradient(90deg, var(--blue), var(--green), var(--yellow));
  transform: scaleX(0);
  transform-origin: left center;
  animation: chart-grow 760ms cubic-bezier(0.22, 0.72, 0.22, 1) forwards;
}

.chart-row strong {
  color: var(--green-dark);
  font-size: 16px;
  text-align: right;
}

.evidence-gallery {
  columns: 3 220px;
  column-gap: 12px;
}

.evidence-gallery img {
  width: 100%;
  display: block;
  break-inside: avoid;
  margin: 0 0 12px;
  border: 3px solid var(--line);
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 4px 4px 0 var(--line);
}

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

.contact-list a {
  display: grid;
  gap: 4px;
  padding: 16px;
  border: 3px solid var(--line);
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 4px 4px 0 var(--line);
  transition: transform 160ms ease, background 160ms ease;
}

.contact-list a:hover,
.contact-list a:focus-visible {
  background: #e5f8ef;
  transform: translate(-2px, -2px);
}

.contact-list span {
  color: var(--green-dark);
  font-size: 13px;
  font-weight: 900;
}

.contact-list strong {
  overflow-wrap: anywhere;
  font-size: 17px;
}

.detail-main {
  padding-top: calc(var(--nav-height) + 46px);
  border-top: 3px solid var(--line);
  border-bottom: 3px solid var(--line);
}

.back-link {
  display: inline-flex;
  margin-bottom: 22px;
  padding: 6px 14px;
  border: 3px solid var(--line);
  border-radius: 999px;
  background: var(--yellow);
  box-shadow: 4px 4px 0 var(--line);
  font-weight: 900;
}

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.72fr);
  gap: clamp(28px, 5vw, 68px);
  align-items: center;
  padding: clamp(26px, 5vw, 50px);
  border: 3px solid var(--line);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

.detail-hero h1 {
  font-size: clamp(34px, 5vw, 62px);
}

.detail-hero p {
  color: var(--muted);
  font-size: 18px;
  font-weight: 700;
}

.detail-hero img {
  width: 100%;
  display: block;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border: 3px solid var(--line);
  border-radius: 16px;
  background: #ffffff;
}

.detail-meta {
  display: flex;
  flex-wrap: nowrap;
  gap: 10px;
  align-items: stretch;
  margin: 28px 0 0;
}

.detail-meta div {
  flex: 1 1 0;
  min-width: 0;
  padding: 12px 14px;
  border: 3px solid var(--line);
  border-radius: 14px;
  background: #fff2a8;
}

.detail-meta dt {
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.detail-meta dd {
  margin: 4px 0 0;
  overflow-wrap: anywhere;
  font-weight: 900;
}

.detail-section {
  margin-top: 28px;
  padding: clamp(24px, 4vw, 42px);
  border: 3px solid var(--line);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 6px 6px 0 var(--line);
}

.detail-text {
  max-width: 920px;
}

.detail-text p {
  color: var(--muted);
  font-size: 17px;
  font-weight: 700;
}

.detail-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.gallery-item {
  display: block;
  margin: 0;
  overflow: hidden;
  border: 3px solid var(--line);
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 4px 4px 0 var(--line);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  display: block;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.empty-state {
  padding: 42px;
  border: 3px solid var(--line);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: var(--shadow);
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes pop-in {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes chart-grow {
  to {
    transform: scaleX(1);
  }
}

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

  .life-collage {
    height: 330px;
  }

  .metric-row,
  .capability-grid,
  .work-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

  .contact-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 720px) {
  :root {
    --nav-height: 66px;
  }

  .site-header {
    width: 100%;
    border-left: 0;
    border-right: 0;
    border-radius: 0;
    padding-inline: 12px;
  }

  .brand strong {
    display: none;
  }

  .brand span {
    width: 42px;
    height: 34px;
    font-size: 18px;
  }

  .nav-links {
    gap: 9px;
    font-size: 12px;
  }

  .section,
  .detail-main {
    width: calc(100% - 18px);
    padding-inline: 14px;
  }

  h1 {
    font-size: 38px;
  }

  .life-collage {
    height: 286px;
  }

  .life-photo-1 {
    left: 6%;
    top: 8%;
    width: 42%;
    height: 50%;
  }

  .life-photo-1 img {
    object-position: 52% 34%;
  }

  .life-photo-2 {
    left: 43%;
    top: 5%;
    width: 35%;
    height: 30%;
  }

  .life-photo-2 img {
    object-position: 50% 38%;
  }

  .life-photo-3 {
    right: 5%;
    top: 31%;
    width: 37%;
    height: 44%;
  }

  .life-photo-3 img {
    object-position: 50% 18%;
  }

  .life-photo-4 {
    left: 18%;
    bottom: 7%;
    width: 38%;
    height: 32%;
  }

  .life-photo-4 img {
    object-position: 50% 36%;
  }

  .life-photo-5 {
    left: 56%;
    bottom: 7%;
    width: 22%;
    height: 25%;
  }

  .life-photo-5 img {
    object-position: 52% 24%;
  }

  .life-photo-6 {
    left: 5%;
    bottom: 13%;
    width: 21%;
    height: 27%;
  }

  .life-photo-6 img {
    object-position: 50% 28%;
  }

  .life-photo-7 {
    display: none;
  }

  .life-photo-8,
  .life-photo-9 {
    display: none;
  }

  .metric-row,
  .capability-grid,
  .work-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .metric-row,
  .capability-grid {
    gap: 10px;
  }

  .metric-row div,
  .capability-grid article {
    min-height: 0;
    padding: 14px;
    border-radius: 14px;
  }

  .metric-row strong {
    font-size: 30px;
  }

  .metric-row span,
  .capability-grid p {
    font-size: 12px;
    line-height: 1.5;
  }

  .capability-grid span {
    margin-bottom: 8px;
    padding: 3px 9px;
    font-size: 12px;
  }

  .detail-meta {
    gap: 6px;
    margin-top: 18px;
  }

  .detail-hero {
    gap: 18px;
    overflow: hidden;
    padding: 18px;
    border-radius: 18px;
  }

  .detail-hero h1 {
    max-width: 100%;
    font-size: 29px;
    line-height: 1.14;
    overflow-wrap: anywhere;
  }

  .detail-hero p:not(.eyebrow) {
    font-size: 14px;
    line-height: 1.65;
  }

  .detail-hero img {
    aspect-ratio: 16 / 9;
    border-radius: 12px;
  }

  .detail-meta div {
    padding: 8px 7px;
    border-width: 2px;
    border-radius: 10px;
  }

  .detail-meta dt {
    font-size: 10px;
    line-height: 1.2;
  }

  .detail-meta dd {
    margin-top: 3px;
    font-size: 11px;
    line-height: 1.28;
  }

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

  .work-card {
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr;
    gap: 0;
    padding: 0;
    border-radius: 14px;
    overflow: hidden;
  }

  .work-card:active {
    box-shadow: 8px 8px 0 var(--line);
    transform: translate(-1px, -2px) scale(1.012);
  }

  .work-card > img {
    grid-column: 1;
    grid-row: 1;
    aspect-ratio: 4 / 3;
    border: 0;
    border-radius: 0;
  }

  .work-category {
    position: absolute;
    top: 7px;
    left: 7px;
    grid-column: auto;
    grid-row: 1;
    width: fit-content;
    max-width: 100%;
    padding: 3px 8px;
    border-width: 2px;
    font-size: 10px;
    line-height: 1.2;
  }

  .work-body {
    grid-column: 1;
    grid-row: 2;
    gap: 6px;
    padding: 10px;
    border-top: 3px solid var(--line);
  }

  .work-meta {
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 3px 6px;
    font-size: 10px;
    line-height: 1.35;
  }

  .work-body h3 {
    min-height: 38px;
    display: -webkit-box;
    overflow: hidden;
    font-size: 14px;
    line-height: 1.34;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .work-body p,
  .work-body strong {
    display: -webkit-box;
    overflow: hidden;
    font-size: 11px;
    line-height: 1.42;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
  }

  .tag-list {
    display: none;
  }

  .timeline-list::before {
    left: 8px;
  }

  .timeline-item {
    grid-template-columns: 22px minmax(0, 1fr);
    padding-bottom: 18px;
  }

  .timeline-date {
    grid-column: 2;
    padding: 0 0 8px;
  }

  .timeline-node {
    grid-row: 1 / span 2;
  }

  .timeline-node::before {
    top: 8px;
    left: -1px;
  }

  .timeline-content {
    grid-column: 2;
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 12px;
    border-radius: 14px;
  }

  .timeline-item:active .timeline-node::before {
    background: var(--orange);
    transform: scale(1.14);
  }

  .timeline-item:active .timeline-content {
    background: #fffdf5;
    box-shadow: 8px 8px 0 var(--line);
    transform: translate(-1px, -2px) scale(1.012);
  }

  .timeline-content img {
    aspect-ratio: 16 / 9;
    border-radius: 10px;
  }

  .timeline-copy {
    gap: 5px;
  }

  .timeline-content strong {
    font-size: 17px;
    line-height: 1.28;
  }

  .timeline-content em {
    font-size: 12px;
    line-height: 1.35;
  }

  .timeline-content small {
    font-size: 12px;
    line-height: 1.45;
  }

  .modal-panel {
    padding: 26px 18px 20px;
  }

  .work-modal {
    padding: 12px;
  }

  .work-modal-panel {
    max-height: 88vh;
  }

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

  .evidence-metrics div {
    min-height: 84px;
    padding: 12px;
  }

  .evidence-metrics strong {
    font-size: 19px;
  }

  .evidence-chart {
    padding: 14px;
  }

  .chart-row {
    grid-template-columns: 92px minmax(0, 1fr) 52px;
    gap: 8px;
  }

  .chart-row span,
  .chart-row strong {
    font-size: 12px;
  }

  .evidence-gallery {
    columns: 1;
  }

  .detail-gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .detail-section {
    margin-top: 22px;
    padding: 18px;
    border-radius: 18px;
  }

  .detail-section h2 {
    margin-bottom: 14px;
    padding: 5px 14px;
    font-size: 25px;
  }

  .detail-text p {
    font-size: 14px;
    line-height: 1.75;
  }

  .gallery-item {
    border-radius: 12px;
    box-shadow: 3px 3px 0 var(--line);
  }
}

@media (max-width: 420px) {
  .nav-links {
    gap: 7px;
    font-size: 11px;
  }

  .hero-actions,
  .contact-actions {
    display: grid;
    width: 100%;
  }

  .button {
    width: 100%;
  }
}

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