:root {
  --bg: #fbfaf7;
  --paper: #ffffff;
  --text: #11110f;
  --muted: #767169;
  --soft: #a8a199;
  --line: #e5e0d7;
  --line-strong: #cbc4b8;
  --space: clamp(18px, 4vw, 48px);
  --max: 1120px;
  --domain-size: clamp(48px, 12.8vw, 132px);
  --ease: cubic-bezier(.16, 1, .3, 1);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  background: var(--bg);
  color: var(--text);
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.72;
  letter-spacing: -0.01em;
  background:
    linear-gradient(90deg, rgba(17, 17, 15, .028) 1px, transparent 1px) center / calc((min(100vw, var(--max)) - var(--space) * 2) / 2) 100%,
    var(--bg);
}

::selection { background: var(--text); color: #fff; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { border: 0; border-radius: 0; background: transparent; color: inherit; font: inherit; }

.skip-link {
  position: fixed;
  left: 16px;
  top: 16px;
  z-index: 50;
  transform: translateY(calc(-100% - 24px));
  padding: 10px 14px;
  background: var(--text);
  color: #fff;
  font-size: 12px;
}
.skip-link:focus { transform: translateY(0); }

.site-header,
.section,
.site-footer {
  width: min(calc(100% - var(--space) * 2), var(--max));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 72px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(18px);
}

.brand,
.nav a,
.eyebrow,
.filter,
.card-meta,
.card-type,
.site-footer,
.modal-kicker,
.spec-label,
.detail-meta,
.project-nav a,
.back-link {
  font-size: 11px;
  line-height: 1;
  letter-spacing: .085em;
  text-transform: uppercase;
}

.brand { font-weight: 560; white-space: nowrap; }
.nav { display: flex; gap: clamp(14px, 3vw, 28px); color: var(--muted); }
.nav a, .brand, .site-footer a, .project-link, .back-link, .project-nav a {
  transition: opacity .35s var(--ease), color .35s var(--ease), border-color .35s var(--ease);
}
.nav a:hover, .brand:hover, .site-footer a:hover, .project-link:hover, .back-link:hover, .project-nav a:hover { opacity: .56; }

.section { padding-block: clamp(60px, 9vw, 118px); }

.hero {
  position: relative;
  min-height: clamp(560px, 76svh, 780px);
  padding-block: 0;
  display: grid;
  place-items: center;
  text-align: center;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #f2eee6;
  isolation: isolate;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(251,250,247,.64), rgba(251,250,247,.38) 42%, rgba(251,250,247,.76)),
    radial-gradient(circle at 50% 44%, rgba(255,255,255,.22), rgba(255,255,255,.62) 72%);
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute;
  inset: clamp(14px, 2vw, 22px);
  z-index: 2;
  border: 1px solid rgba(17,17,15,.08);
  pointer-events: none;
}
.hero-inner {
  position: relative;
  z-index: 3;
  width: min(100% - 32px, 900px);
  padding: clamp(40px, 8vw, 92px) 0;
}
.eyebrow { margin: 0 0 30px; color: var(--muted); }
h1, h2, h3, p { margin: 0; }
h1 {
  font-size: clamp(72px, 15.5vw, 188px);
  line-height: .88;
  letter-spacing: -.074em;
  font-weight: 455;
  text-wrap: balance;
}
.hero-title-domain {
  font-size: var(--domain-size);
  letter-spacing: -.058em;
  white-space: nowrap;
}
.hero-title-word {
  font-size: clamp(92px, 20vw, 232px);
  letter-spacing: -.084em;
  text-shadow: 0 1px 24px rgba(251,250,247,.92);
}
.hero-flow {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  overflow: hidden;
  border: 0;
  mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent);
}
.hero-flow::before,
.hero-flow::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 1;
  width: 12%;
  pointer-events: none;
}
.hero-flow::before { left: 0; background: linear-gradient(90deg, var(--bg), transparent); }
.hero-flow::after { right: 0; background: linear-gradient(270deg, var(--bg), transparent); }
.hero-track {
  display: flex;
  width: max-content;
  height: 100%;
  animation: heroMarquee 42s linear infinite;
  will-change: transform;
}
.hero-set {
  display: flex;
  align-items: stretch;
  gap: clamp(4px, .8vw, 10px);
  height: 100%;
  padding: 0 clamp(2px, .4vw, 5px);
}
.hero-set img {
  width: clamp(260px, 33vw, 430px);
  height: 100%;
  object-fit: cover;
  border: 0;
  background: #eeeae2;
  filter: grayscale(.12) saturate(.58) contrast(1.04);
  opacity: .66;
}
@keyframes heroMarquee {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(-50%, 0, 0); }
}
.hero-copy {
  width: min(100%, 610px);
  margin: 30px auto 0;
  color: #5f5a52;
  font-size: clamp(14px, 1.45vw, 17px);
  line-height: 1.9;
  text-wrap: pretty;
  text-shadow: 0 1px 18px rgba(251,250,247,.96);
}

.section-head {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 24px;
  padding-bottom: 26px;
  border-bottom: 1px solid var(--line);
}
.section-head h2 {
  font-size: clamp(30px, 4.4vw, 58px);
  line-height: .96;
  letter-spacing: -.055em;
  font-weight: 465;
}
.filters { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.filter {
  cursor: pointer;
  color: var(--muted);
  padding: 10px 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .36);
  transition: color .35s var(--ease), border-color .35s var(--ease), background .35s var(--ease);
}
.filter:hover, .filter.is-active { color: var(--text); border-color: var(--text); background: rgba(255,255,255,.76); }

.concept-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(24px, 4vw, 48px);
  padding-top: clamp(30px, 5vw, 56px);
}
.concept-card {
  display: grid;
  width: 100%;
  min-width: 0;
  text-align: left;
  cursor: pointer;
  transition: opacity .35s var(--ease), transform .55s var(--ease);
}
.concept-card.is-hidden { display: none; }
.image-frame {
  position: relative;
  display: block;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #eeeae2;
}
.image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(.82) contrast(.99);
  transform: scale(1.001);
  transition: transform .9s var(--ease), filter .9s var(--ease);
}
.image-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 10px solid rgba(255,255,255,.18);
  opacity: 0;
  transition: opacity .5s var(--ease), border-width .5s var(--ease);
  pointer-events: none;
}
.card-meta {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 18px;
  color: var(--muted);
}
.card-title {
  display: block;
  margin-top: 8px;
  font-size: clamp(25px, 3.35vw, 40px);
  line-height: .96;
  letter-spacing: -.052em;
  font-weight: 458;
}
.card-type {
  display: block;
  margin-top: 13px;
  color: var(--soft);
}
.card-summary {
  margin-top: 14px;
  max-width: 92%;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.82;
}

@media (hover: hover) {
  .concept-card:hover { transform: translateY(-3px); }
  .concept-card:hover .image-frame img { transform: scale(1.023); filter: saturate(.75) contrast(1.04); }
  .concept-card:hover .image-frame::after { opacity: 1; border-width: 7px; }
}

.method {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(30px, 5vw, 60px);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.method h2 {
  font-size: clamp(34px, 5vw, 72px);
  line-height: .98;
  letter-spacing: -.06em;
  font-weight: 455;
}
.method-copy {
  align-self: end;
  color: var(--muted);
  font-size: clamp(14px, 1.5vw, 17px);
  line-height: 1.95;
}
.method-list {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
}
.method-item { padding: 24px 0 0; }
.method-item + .method-item { border-left: 1px solid var(--line); padding-left: clamp(18px, 3vw, 34px); }
.method-item h3 {
  font-size: 13px;
  letter-spacing: .05em;
  text-transform: uppercase;
  font-weight: 560;
}
.method-item p { margin-top: 12px; color: var(--muted); font-size: 14px; line-height: 1.8; }

.site-footer {
  min-height: 86px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: var(--muted);
}

.concept-modal {
  width: min(calc(100% - 28px), 1060px);
  max-height: calc(100svh - 28px);
  padding: 0;
  border: 1px solid var(--line-strong);
  background: var(--bg);
  color: var(--text);
}
.concept-modal::backdrop { background: rgba(251,250,247,.8); backdrop-filter: blur(14px); }
.concept-modal[open] { animation: modalIn .42s var(--ease) both; }
.modal-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, .96fr);
  gap: clamp(24px, 5vw, 62px);
  padding: clamp(24px, 5vw, 58px);
}
.modal-image {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border: 1px solid var(--line);
  background: #eeeae2;
  filter: saturate(.82) contrast(.99);
}
.modal-copy { align-self: end; padding-bottom: 2px; }
.modal-kicker { margin-bottom: 24px; color: var(--muted); }
.modal-title {
  font-size: clamp(42px, 6vw, 82px);
  line-height: .9;
  letter-spacing: -.07em;
  font-weight: 455;
}
.modal-summary {
  margin-top: 26px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.9;
}
.spec-list {
  display: grid;
  gap: 0;
  margin: 28px 0 0;
  padding: 0;
  border-top: 1px solid var(--line);
}
.spec-row {
  display: grid;
  grid-template-columns: 98px 1fr;
  gap: 20px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.spec-label { color: var(--soft); }
.spec-value { color: var(--text); font-size: 14px; line-height: 1.72; }
.modal-actions { display: flex; gap: 12px; margin-top: 28px; }
.project-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--text);
  font-size: 12px;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.project-link.secondary { border-color: var(--line-strong); color: var(--muted); }

.detail-main .section { padding-block: clamp(48px, 8vw, 96px); }
.detail-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 5vw, 58px);
  align-items: end;
  border-bottom: 1px solid var(--line);
}
.detail-title {
  font-size: clamp(64px, 10.8vw, 142px);
  line-height: .9;
  letter-spacing: -.073em;
  font-weight: 455;
  text-wrap: balance;
}
.detail-lead {
  margin-top: 28px;
  color: var(--muted);
  font-size: clamp(15px, 1.55vw, 18px);
  line-height: 1.9;
  text-wrap: pretty;
}
.detail-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 18px;
  margin-top: 30px;
  color: var(--muted);
}
.detail-cover {
  aspect-ratio: 4 / 5;
  width: 100%;
  object-fit: cover;
  border: 1px solid var(--line);
  background: #eeeae2;
  filter: saturate(.82) contrast(.99);
}
.back-link { display: inline-flex; margin-bottom: 34px; color: var(--muted); }
.detail-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 5vw, 56px);
  border-bottom: 1px solid var(--line);
}
.detail-section { border-top: 1px solid var(--line); padding-top: 22px; }
.detail-section h2 {
  font-size: 13px;
  letter-spacing: .05em;
  text-transform: uppercase;
  font-weight: 560;
}
.detail-section p { margin-top: 18px; color: var(--muted); line-height: 1.95; }
.detail-wide { grid-column: 1 / -1; }
.project-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(20px, 4vw, 48px);
}
.project-nav a {
  display: grid;
  gap: 12px;
  min-height: 120px;
  align-content: center;
  border-top: 1px solid var(--line);
  color: var(--muted);
}
.project-nav strong {
  display: block;
  color: var(--text);
  font-size: clamp(26px, 3.8vw, 42px);
  line-height: .98;
  letter-spacing: -.055em;
  font-weight: 455;
  text-transform: none;
}

.js .reveal { opacity: 0; transform: translateY(14px); }
.js .reveal.is-visible { opacity: 1; transform: translateY(0); transition: opacity .78s var(--ease), transform .78s var(--ease); }
@keyframes modalIn { from { opacity: 0; transform: translateY(12px) scale(.986); } to { opacity: 1; transform: translateY(0) scale(1); } }

@media (max-width: 760px) {
  :root { --space: 18px; }
  body {
    background:
      linear-gradient(90deg, rgba(17, 17, 15, .028) 1px, transparent 1px) center / calc((100vw - var(--space) * 2) / 2) 100%,
      var(--bg);
  }
  .site-header { height: 64px; }
  .nav { gap: 16px; }
  .nav a { font-size: 10px; letter-spacing: .065em; }
  .hero { min-height: 72svh; padding-block: 0; }
  h1 { font-size: clamp(76px, 21vw, 112px); }
  .hero-title-domain { font-size: clamp(42px, 12vw, 58px); letter-spacing: -.052em; }
  .hero-title-word { font-size: clamp(86px, 27vw, 128px); }
  .hero-inner { width: min(100% - 28px, 620px); }
  .hero-flow { width: 100%; margin-top: 0; }
  .hero-set { gap: 4px; }
  .hero-set img { width: clamp(210px, 62vw, 280px); opacity: .64; }
  .section-head { grid-template-columns: 1fr; align-items: start; }
  .filters { justify-content: flex-start; }
  .concept-grid { grid-template-columns: 1fr; }
  .card-summary { max-width: 100%; }
  .method, .detail-hero, .detail-content { grid-template-columns: 1fr; }
  .method-list { grid-template-columns: 1fr; }
  .method-item + .method-item { border-left: 0; padding-left: 0; }
  .modal-grid { grid-template-columns: 1fr; }
  .modal-copy { align-self: start; }
  .modal-actions { flex-direction: column; align-items: stretch; }
  .project-link { width: 100%; }
  .detail-title { font-size: clamp(58px, 16vw, 86px); }
  .project-nav { grid-template-columns: 1fr; }
  .site-footer { align-items: flex-start; flex-direction: column; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .js .reveal { opacity: 1; transform: none; }
  .hero-track { animation: none; transform: translate3d(0,0,0); }
}

/* Refinements requested: safer width, cleaner principles, simpler footer */
html,
body {
  max-width: 100%;
  overflow-x: clip;
}

.hero-inner,
.section-head,
.concept-grid,
.method,
.site-footer {
  min-width: 0;
}

.hero-title-word {
  max-width: 100%;
  overflow-wrap: normal;
}

.method-copy span {
  display: block;
}

.method-list {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.method-item {
  min-width: 0;
  padding: 28px clamp(24px, 3.6vw, 46px) 0;
}

.method-item:first-child {
  padding-left: 0;
}

.method-item:last-child {
  padding-right: 0;
}

.method-item + .method-item {
  border-left: 1px solid var(--line);
  padding-left: clamp(28px, 4.2vw, 54px);
}

.site-footer {
  justify-content: flex-start;
}

@media (max-width: 760px) {
  .site-header,
  .section,
  .site-footer {
    width: calc(100% - var(--space) * 2);
  }

  .hero-title-word {
    font-size: clamp(80px, 25vw, 118px);
    letter-spacing: -.078em;
  }

  .method-copy span {
    display: inline;
  }

  .method-copy span + span::before {
    content: "";
    display: block;
    height: .3em;
  }

  .method-item {
    padding: 24px 0 0;
  }

  .method-item + .method-item {
    border-left: 0;
    border-top: 1px solid var(--line);
    margin-top: 24px;
    padding-left: 0;
  }
}

/* Layout fix: Principles should not crowd at narrow widths */
.method-list {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}

.method-item {
  min-width: 0;
  padding: 30px clamp(34px, 4vw, 60px) 0;
}

.method-item:first-child {
  padding-left: 0;
  padding-right: clamp(34px, 4vw, 60px);
}

.method-item:last-child {
  padding-left: clamp(34px, 4vw, 60px);
  padding-right: 0;
}

.method-item + .method-item {
  border-left: 1px solid var(--line);
  padding-left: clamp(34px, 4vw, 60px);
}

.method-item p {
  max-width: 34em;
}

/* Color sample images: keep the site minimal, but let the concept visuals breathe. */
.hero-set img {
  filter: saturate(.96) contrast(1.02);
  opacity: .74;
}

.concept-card:nth-child(-n+4) .image-frame img,
.detail-cover[src*="project-01"],
.detail-cover[src*="project-02"],
.detail-cover[src*="project-03"],
.detail-cover[src*="project-04"] {
  filter: saturate(.96) contrast(1.02);
}

@media (max-width: 980px) {
  .method-list {
    grid-template-columns: 1fr;
    border-top: 1px solid var(--line);
  }

  .method-item,
  .method-item:first-child,
  .method-item:last-child {
    padding: 28px 0 0;
  }

  .method-item + .method-item {
    border-left: 0;
    border-top: 1px solid var(--line);
    margin-top: 28px;
    padding-left: 0;
  }

  .method-item h3,
  .method-item p {
    max-width: 620px;
  }
}

@media (max-width: 760px) {
  .method-item,
  .method-item:first-child,
  .method-item:last-child {
    padding-top: 24px;
  }

  .method-item + .method-item {
    margin-top: 24px;
  }
}

/* Generated content helpers */
.concept-empty {
  grid-column: 1 / -1;
  margin: 0;
  padding: 48px 0;
  color: var(--muted);
  border-top: 1px solid var(--line);
}

.detail-body h2,
.detail-body h3 {
  font-size: 13px;
  letter-spacing: .05em;
  text-transform: uppercase;
  font-weight: 560;
}

.detail-body h3 {
  margin-top: 26px;
  color: var(--text);
}

.detail-body p,
.detail-body ul {
  margin-top: 18px;
  color: var(--muted);
  line-height: 1.95;
}

.detail-body ul {
  padding-left: 1.1em;
}

.detail-body li + li {
  margin-top: 8px;
}

.detail-body code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: .92em;
}

.detail-cover,
.modal-image,
.concept-card .image-frame img {
  filter: saturate(.96) contrast(1.02);
}
