/* JUNKBRANDING — Demo #04 stylesheet. Scoped to this demo only. */

/* ---------- Tokens ---------- */
:root {
  --paper: #f5f5f3;
  --ink: #0d0d0e;
  --stone: #6a6a66;
  --ash: #9c9c97;
  --cobalt: #2a44e0;
  --cobalt-bright: #6b80ff;

  --bg: var(--paper);
  --fg: var(--ink);
  --muted: var(--stone);
  --line: color-mix(in srgb, var(--ink) 14%, transparent);
  --accent: var(--cobalt);

  --font-display: 'Archivo', 'Noto Sans JP', system-ui, sans-serif;
  --font-body: 'Archivo', 'Noto Sans JP', system-ui, sans-serif;

  --pad: clamp(1.25rem, 4vw, 3rem);
  --gap: clamp(1rem, 2vw, 1.75rem);
  --section: clamp(5rem, 12vw, 10rem);
  --header-h: 4.25rem;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --radius: 0.25rem;
  color-scheme: light;
}

[data-theme='dark'] {
  --bg: var(--ink);
  --fg: var(--paper);
  --muted: var(--ash);
  --line: color-mix(in srgb, var(--paper) 16%, transparent);
  --accent: var(--cobalt-bright);
  color-scheme: dark;
}

/* ---------- Base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
  background: var(--bg);
  color: var(--fg);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 1rem);
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.75;
  font-feature-settings: 'palt' 0;
  background: var(--bg);
  color: var(--fg);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

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

h1, h2, h3, p, ul, ol, dl, dd, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
address { font-style: normal; }
table { border-collapse: collapse; width: 100%; }
[hidden] { display: none !important; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 2px;
}
main:focus { outline: none; }

::selection { background: var(--accent); color: var(--paper); }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
  position: fixed; top: 0.75rem; left: 0.75rem; z-index: 100;
  padding: 0.6rem 1rem; background: var(--fg); color: var(--bg);
  transform: translateY(-200%);
}
.skip-link:focus { transform: none; }

/* ---------- Type primitives ---------- */
.eyebrow,
.footer-heading,
.journal-meta,
.work-card__tags,
.crumbs,
.hero__meta,
.filter__btn sup {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-stretch: 100%;
  color: var(--muted);
  font-weight: 500;
}

.section-title {
  font-family: var(--font-display);
  font-stretch: 112%;
  font-weight: 600;
  font-size: clamp(1.75rem, 3.4vw, 3rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
}

.page-title {
  font-family: var(--font-display);
  font-stretch: 118%;
  font-weight: 700;
  font-size: clamp(2.6rem, 8.2vw, 8.5rem);
  line-height: 0.92;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.page-lead {
  max-width: 36rem;
  font-size: clamp(1rem, 1.2vw, 1.125rem);
  line-height: 1.85;
  color: var(--muted);
  text-wrap: pretty;
}

.text-link {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: 0.9375rem; font-weight: 500;
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat;
  padding-bottom: 0.15rem;
  transition: background-size 0.5s var(--ease-out), color 0.2s;
}
.text-link::after { content: '→'; font-family: var(--font-display); transition: transform 0.4s var(--ease-out); }
.text-link:hover { background-size: 0 1px; background-position: 100% 100%; color: var(--accent); }
.text-link:hover::after { transform: translateX(0.25rem); }

/* Split titles (JS wraps words) */
.word { display: inline-block; overflow: clip; vertical-align: top; padding-bottom: 0.06em; margin-bottom: -0.06em; }
.word__inner { display: inline-block; will-change: transform; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto; z-index: 40;
  height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between; gap: 2rem;
  padding-inline: var(--pad);
  color: var(--fg);
  transition: transform 0.6s var(--ease-out), background-color 0.3s;
}
.site-header.is-hidden { transform: translateY(-100%); }
.site-header.is-solid { background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(10px); }

.wordmark {
  font-family: var(--font-display);
  font-weight: 800; font-stretch: 125%;
  font-size: 1.0625rem; letter-spacing: -0.02em; line-height: 1;
}

.site-nav { display: none; }
.site-nav ul { display: flex; gap: clamp(1.25rem, 2.5vw, 2.5rem); }
.site-nav a {
  position: relative; font-size: 0.875rem; font-weight: 500;
  font-family: var(--font-display); letter-spacing: 0.01em;
}
.site-nav a::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -0.3rem; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: right;
  transition: transform 0.5s var(--ease-out);
}
.site-nav a:hover::after,
.site-nav a[aria-current='page']::after { transform: scaleX(1); transform-origin: left; }

.menu-toggle {
  display: inline-flex; align-items: center; gap: 0.75rem;
  background: none; border: 0; padding: 0.5rem 0;
  font-family: var(--font-display); font-weight: 500; font-size: 0.875rem;
  min-height: 2.75rem;
}
.menu-toggle__bars { display: grid; gap: 5px; width: 1.5rem; }
.menu-toggle__bars span { height: 1.5px; background: currentColor; transition: transform 0.4s var(--ease-out); }
.menu-toggle:hover .menu-toggle__bars span:last-child { transform: scaleX(0.6); transform-origin: right; }

@media (min-width: 900px) {
  .site-nav { display: block; }
  .site-header .menu-toggle { display: none; }
}

/* ---------- Menu overlay ---------- */
.menu {
  position: fixed; inset: 0; z-index: 60;
  background: var(--ink); color: var(--paper);
  --fg: var(--paper); --muted: var(--ash); --accent: var(--cobalt-bright);
  overflow-y: auto;
}
.menu__panel { min-height: 100%; display: flex; flex-direction: column; padding: 0 var(--pad) var(--pad); }
.menu__top { height: var(--header-h); display: flex; align-items: center; justify-content: space-between; }
.menu__list { display: flex; flex-direction: column; padding-block: 2rem; border-top: 1px solid var(--line); }
.menu__item { overflow: clip; border-bottom: 1px solid var(--line); }
.menu__item a {
  display: flex; align-items: baseline; justify-content: space-between; gap: 1rem;
  padding-block: 0.9rem;
}
.menu__label {
  font-family: var(--font-display); font-weight: 700; font-stretch: 120%;
  font-size: clamp(2.5rem, 12vw, 5rem); line-height: 1; letter-spacing: -0.03em;
}
.menu__ja { font-size: 0.8125rem; color: var(--muted); }
.menu__item a[aria-current='page'] .menu__label { color: var(--accent); }
.menu__foot { margin-top: auto; display: flex; flex-direction: column; gap: 0.25rem; font-size: 0.875rem; color: var(--muted); }

/* ---------- Main / sections ---------- */
main { display: block; }
.section { padding: var(--section) var(--pad) 0; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: clamp(2rem, 5vw, 4rem); }

/* ---------- Hero (home) ---------- */
.hero {
  min-height: 100svh;
  display: grid;
  grid-template-rows: 1fr auto auto;
  gap: clamp(1.5rem, 4vw, 3rem);
  padding: calc(var(--header-h) + 2rem) var(--pad) clamp(2rem, 5vw, 3.5rem);
}
@media (max-width: 47.99rem) {
  .hero { min-height: auto; grid-template-rows: auto auto auto; gap: 2.5rem; padding-top: calc(var(--header-h) + 1.5rem); }
  .hero .hero__title { font-size: clamp(2.6rem, 12.4vw, 5rem); }
  }
  .hero__meta { display: flex; flex-wrap: wrap; gap: 0.5rem 2rem; align-self: start; }
.hero__title {
  font-family: var(--font-display);
  font-weight: 700; font-stretch: 125%;
  font-size: clamp(2.6rem, 10.6vw, 11.5rem);
  line-height: 0.9; letter-spacing: -0.045em;
  display: flex; flex-direction: column;
}
.line { display: flex; align-items: center; gap: 0.2em; overflow: clip; padding-bottom: 0.04em; }
.line__inner { display: inline-block; }
.line--media { overflow: visible; }

.hero__pill {
  position: relative; flex: none;
  width: 1.9em; height: 0.78em;
  border-radius: 999px; overflow: hidden;
  background: var(--ink);
  transform-origin: left center;
}
.hero__slide { position: absolute; inset: 0; opacity: 0; transition: opacity 0.9s var(--ease-out); }
.hero__slide.is-active { opacity: 1; }
.hero__slide img { width: 100%; height: 100%; object-fit: cover; }
.hero__pill-label {
  position: absolute; left: 50%; bottom: 0.5rem; transform: translateX(-50%);
  font-size: 0.625rem; font-weight: 500; letter-spacing: 0.06em; text-transform: uppercase;
  font-stretch: 100%; white-space: nowrap;
  padding: 0.15rem 0.5rem; border-radius: 999px;
  background: var(--paper); color: var(--ink);
  display: none;
}
@media (min-width: 700px) {
  .hero__pill { width: 2.4em; }
  .hero__pill-label { display: block; }
}

.hero__intro {
  display: grid; gap: 1.25rem; justify-items: start;
  max-width: 34rem; justify-self: end;
  font-size: 0.9375rem; line-height: 1.85;
}

/* Initial hidden state only when motion runs (set by boot.js). */
.motion .hero [data-hero-line],
.motion .hero [data-hero-meta] > *,
.motion .hero [data-hero-intro] { visibility: hidden; }

/* ---------- Feature ---------- */
.feature { padding-inline: var(--pad); }
.feature__link { display: block; }
.feature__media { aspect-ratio: 16 / 9; overflow: hidden; background: var(--line); border-radius: var(--radius); }
.feature__media img { width: 100%; height: 100%; object-fit: cover; }
.feature__caption { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding-top: 1rem; }
.feature__title { font-family: var(--font-display); font-weight: 600; font-stretch: 112%; font-size: clamp(1.25rem, 2vw, 1.75rem); line-height: 1.2; display: flex; flex-direction: column; text-align: right; }
.feature__title span { font-family: var(--font-body); font-weight: 400; font-stretch: 100%; font-size: 0.875rem; color: var(--muted); }

/* ---------- Work card ---------- */
.work-card__link { display: block; }
.work-card__media { overflow: hidden; background: var(--line); border-radius: var(--radius); aspect-ratio: 3 / 2; }
.work-card__img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease-out); }
.work-card__link:hover .work-card__img { transform: scale(1.035); }
.work-card__meta { display: grid; grid-template-columns: 1fr auto; gap: 0.25rem 1rem; padding-top: 1rem; }
.work-card__title {
  font-family: var(--font-display); font-weight: 600; font-stretch: 112%;
  font-size: clamp(1.25rem, 1.8vw, 1.625rem); line-height: 1.15; letter-spacing: -0.01em;
  transition: color 0.2s;
}
.work-card__link:hover .work-card__title { color: var(--accent); }
.work-card__sub { grid-column: 1 / -1; font-size: 0.875rem; color: var(--muted); line-height: 1.6; }
.work-card__tags { grid-column: 1 / -1; display: flex; justify-content: space-between; gap: 1rem; margin-top: 0.5rem; padding-top: 0.75rem; border-top: 1px solid var(--line); }

/* Home: asymmetric selected grid */
.selected__grid { display: grid; gap: clamp(3rem, 6vw, 5rem) var(--gap); }
@media (min-width: 900px) {
  .selected__grid { grid-template-columns: repeat(12, 1fr); }
  .selected__item--1 { grid-column: 1 / span 7; }
  .selected__item--1 .work-card__media { aspect-ratio: 4 / 3; }
  .selected__item--2 { grid-column: 9 / span 4; align-self: end; }
  .selected__item--2 .work-card__media { aspect-ratio: 4 / 5; }
  .selected__item--3 { grid-column: 4 / span 6; }
}

/* ---------- Approach ---------- */
.approach { display: grid; gap: 2.5rem; }
.approach__title {
  font-family: var(--font-display); font-weight: 600; font-stretch: 118%;
  font-size: clamp(2rem, 5.4vw, 5.25rem); line-height: 0.98; letter-spacing: -0.03em;
  max-width: 14ch; text-wrap: balance;
}
.approach__cols { display: grid; gap: 1.5rem; max-width: 44rem; color: var(--muted); }
@media (min-width: 900px) {
  .approach { grid-template-columns: repeat(12, 1fr); }
  .approach__title { grid-column: 1 / span 9; }
  .approach__cols { grid-column: 6 / span 7; grid-template-columns: 1fr 1fr; gap: var(--gap); }
}

/* ---------- Disciplines list ---------- */
.disc__list { border-top: 1px solid var(--line); }
.disc__row { border-bottom: 1px solid var(--line); }
.disc__row a {
  display: grid; gap: 0.25rem 1.5rem; padding-block: 1.5rem;
  grid-template-columns: 1fr;
  transition: color 0.25s, padding 0.6s var(--ease-out);
}
.disc__label {
  font-family: var(--font-display); font-weight: 600; font-stretch: 120%;
  font-size: clamp(1.75rem, 4.4vw, 4rem); line-height: 1; letter-spacing: -0.03em;
}
.disc__ja { font-size: 0.8125rem; color: var(--muted); }
.disc__lead { font-size: 0.9375rem; color: var(--muted); max-width: 32rem; }
.disc__row a:hover { color: var(--accent); padding-left: 1rem; }
@media (min-width: 900px) {
  .disc__row a { grid-template-columns: 5fr 2fr 4fr; align-items: center; }
}

/* ---------- Clients ---------- */
.clients__list {
  display: grid; grid-template-columns: repeat(2, 1fr);
  border-top: 1px solid var(--line); border-left: 1px solid var(--line);
  margin-top: 2rem;
}
.clients__list li {
  padding: 1.5rem 1rem; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line);
  font-family: var(--font-display); font-weight: 500; font-stretch: 108%; font-size: 0.9375rem;
}
@media (min-width: 700px) { .clients__list { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Journal ---------- */
.journal-list { border-top: 1px solid var(--line); }
.journal-row { border-bottom: 1px solid var(--line); }
.journal-row a {
  display: grid; gap: 0.25rem 2rem; padding-block: 1.25rem;
  grid-template-columns: 1fr auto;
}
.journal-row__cat, .journal-row time { font-size: 0.75rem; color: var(--muted); font-family: var(--font-display); letter-spacing: 0.06em; text-transform: uppercase; }
.journal-row__title { grid-column: 1 / -1; grid-row: 2; font-size: clamp(1rem, 1.6vw, 1.25rem); font-weight: 500; line-height: 1.6; transition: color 0.2s; }
.journal-row a:hover .journal-row__title { color: var(--accent); }
@media (min-width: 900px) {
  .journal-row a { grid-template-columns: 10rem 1fr auto; align-items: baseline; }
  .journal-row__title { grid-column: 2; grid-row: 1; }
}
.journal-meta { display: flex; gap: 1rem; }

/* ---------- Page hero (inner pages) ---------- */
.page-hero {
  display: grid; gap: clamp(1.5rem, 3vw, 2.5rem);
  padding: calc(var(--header-h) + clamp(3rem, 10vw, 8rem)) var(--pad) clamp(3rem, 6vw, 5rem);
}
.page-hero .page-title { max-width: 16ch; }
@media (min-width: 900px) {
  .page-hero { grid-template-columns: repeat(12, 1fr); }
  .page-hero > * { grid-column: 1 / -1; }
  .page-hero .page-lead { grid-column: 7 / span 6; }
  .page-hero--works .page-title { max-width: 12ch; }
}

/* ---------- Studio ---------- */
.studio-hero-media { margin-inline: var(--pad); overflow: hidden; border-radius: var(--radius); aspect-ratio: 16 / 10; }
.studio-hero-media img, .process__media img, .ed-grid__media img { width: 100%; height: 115%; object-fit: cover; }
.studio-hero-media figcaption { font-size: 0.75rem; color: var(--muted); padding-top: 0.75rem; }
.studio-hero-media { display: flex; flex-direction: column; aspect-ratio: auto; overflow: visible; }
.studio-hero-media picture { aspect-ratio: 16 / 10; overflow: hidden; border-radius: var(--radius); }

.statement { display: grid; gap: 2rem; }
.statement__en {
  font-family: var(--font-display); font-weight: 600; font-stretch: 112%;
  font-size: clamp(1.75rem, 4.2vw, 4rem); line-height: 1.08; letter-spacing: -0.025em;
  max-width: 22ch; text-wrap: pretty;
}
.statement__ja { max-width: 36rem; color: var(--muted); }
@media (min-width: 900px) { .statement__ja { margin-left: auto; } }

.principles__grid { display: grid; gap: 3rem var(--gap); margin-top: 3rem; }
.principle { display: grid; gap: 0.75rem; align-content: start; padding-top: 1.25rem; border-top: 1px solid var(--fg); }
.principle__en { font-family: var(--font-display); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.principle__title { font-size: 1.375rem; font-weight: 700; line-height: 1.4; }
.principle p:last-child { color: var(--muted); font-size: 0.9375rem; }
@media (min-width: 900px) {
  .principles__grid { grid-template-columns: repeat(3, 1fr); }
  .principle:nth-child(2) { margin-top: 5rem; }
  .principle:nth-child(3) { margin-top: 10rem; }
}

.facts__list { display: grid; grid-template-columns: repeat(2, 1fr); border-top: 1px solid var(--line); }
.facts__list div { padding: 1.5rem 0; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 0.25rem; }
.facts__list dt { font-family: var(--font-display); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.facts__list dd { font-family: var(--font-display); font-weight: 600; font-stretch: 118%; font-size: clamp(2.5rem, 6vw, 5rem); line-height: 1; letter-spacing: -0.04em; }
@media (min-width: 900px) { .facts__list { grid-template-columns: repeat(4, 1fr); } }

.history { padding-top: var(--section); }
.history__pin { padding-inline: var(--pad); }
.history__title { margin-bottom: 2.5rem; }
.history__track { display: grid; gap: 0; border-top: 1px solid var(--line); }
.history__item { display: grid; grid-template-columns: 5rem 1fr; gap: 1rem; padding-block: 1.5rem; border-bottom: 1px solid var(--line); }
.history__year { font-family: var(--font-display); font-weight: 600; font-stretch: 118%; font-size: 1.25rem; }
.history__text { font-size: 0.9375rem; color: var(--muted); }

/* Horizontal history only when JS motion is active on wide screens */
@media (min-width: 900px) {
  .motion .history__pin { height: 100svh; display: flex; flex-direction: column; justify-content: center; overflow: hidden; }
  .motion .history__track { display: flex; width: max-content; border-top: 0; gap: 0; }
  .motion .history__item {
    width: min(30rem, 34vw); grid-template-columns: 1fr; align-content: start; gap: 1.5rem;
    padding: 2rem 2.5rem 0 0; border-bottom: 0; border-top: 1px solid var(--fg); margin-right: 2.5rem;
  }
  .motion .history__year { font-size: clamp(4rem, 9vw, 8rem); line-height: 0.9; letter-spacing: -0.05em; }
}

.process { display: grid; gap: 2.5rem; }
.process__media { overflow: hidden; border-radius: var(--radius); aspect-ratio: 4 / 5; }
.process__text { display: grid; gap: 1.25rem; align-content: start; max-width: 34rem; }
.process__text p { color: var(--muted); }
@media (min-width: 900px) {
  .process { grid-template-columns: repeat(12, 1fr); }
  .process__media { grid-column: 1 / span 5; }
  .process__text { grid-column: 7 / span 5; align-self: center; }
}

.awards__table { margin-top: 2.5rem; font-size: 0.9375rem; }
.awards__table th { text-align: left; font-family: var(--font-display); font-size: 0.75rem; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); padding: 0 1rem 0.75rem 0; border-bottom: 1px solid var(--fg); }
.awards__table td { padding: 1.1rem 1rem 1.1rem 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.awards__table td:nth-child(2) { font-family: var(--font-display); font-weight: 600; font-stretch: 108%; }
@media (max-width: 699px) {
  .awards__table thead { display: none; }
  .awards__table tr { display: grid; grid-template-columns: 4rem 1fr; padding-block: 1rem; border-bottom: 1px solid var(--line); }
  .awards__table td { border: 0; padding: 0; }
  .awards__table td:nth-child(3) { grid-column: 2; color: var(--muted); }
}

.careers { display: grid; gap: 1.5rem; }
.careers__body { display: grid; gap: 1.25rem; justify-items: start; max-width: 36rem; }
@media (min-width: 900px) { .careers { grid-template-columns: 1fr 1fr; } }

/* ---------- Expertise ---------- */
.exp-index { padding-inline: var(--pad); position: sticky; top: 0; z-index: 5; }
.exp-index ul { display: flex; gap: 0.5rem; overflow-x: auto; padding-block: 1rem; scrollbar-width: none; }
.exp-index a {
  display: inline-flex; white-space: nowrap; padding: 0.5rem 1rem; border: 1px solid var(--line); border-radius: 999px;
  font-family: var(--font-display); font-size: 0.8125rem; font-weight: 500; background: var(--bg);
  transition: background-color 0.2s, color 0.2s, border-color 0.2s;
}
.exp-index a:hover, .exp-index a.is-active { background: var(--fg); color: var(--bg); border-color: var(--fg); }

.exp { display: grid; gap: 2rem; padding: var(--section) var(--pad) 0; }
.exp__title { font-family: var(--font-display); font-weight: 700; font-stretch: 120%; font-size: clamp(2.25rem, 6vw, 5.5rem); line-height: 0.95; letter-spacing: -0.035em; }
.exp__ja { margin-top: 0.75rem; font-size: 0.875rem; color: var(--muted); }
.exp__media { margin-top: 2rem; aspect-ratio: 4 / 3; overflow: hidden; border-radius: var(--radius); }
.exp__media img { width: 100%; height: 100%; object-fit: cover; }
.exp__main { display: grid; gap: 1.5rem; align-content: start; }
.exp__lead { font-size: clamp(1.25rem, 2vw, 1.625rem); line-height: 1.6; font-weight: 500; text-wrap: pretty; }
.exp__body { color: var(--muted); }
.exp__subhead { margin-top: 1.5rem; font-family: var(--font-display); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); font-weight: 500; }
.exp__deliverables { border-top: 1px solid var(--fg); }
.exp__deliverables li { padding-block: 0.9rem; border-bottom: 1px solid var(--line); font-weight: 500; display: flex; gap: 1rem; }
.exp__deliverables li::before { content: ''; width: 0.5rem; height: 0.5rem; margin-top: 0.65rem; flex: none; background: var(--accent); }
.exp__related a { display: flex; justify-content: space-between; gap: 1rem; padding-block: 0.75rem; border-bottom: 1px solid var(--line); font-size: 0.9375rem; }
.exp__related a span:first-child { font-family: var(--font-display); font-weight: 600; }
.exp__related a span:last-child { color: var(--muted); }
.exp__related a:hover span:first-child { color: var(--accent); }
@media (min-width: 900px) {
  .exp { grid-template-columns: repeat(12, 1fr); gap: var(--gap); }
  .exp__aside { grid-column: 1 / span 5; }
  .exp__sticky { position: sticky; top: calc(var(--header-h) + 4rem); }
  .exp__main { grid-column: 7 / span 6; }
  .exp:nth-of-type(even) .exp__aside { grid-column: 8 / span 5; grid-row: 1; }
  .exp:nth-of-type(even) .exp__main { grid-column: 1 / span 6; grid-row: 1; }
}

/* ---------- Works index ---------- */
.filter { padding-inline: var(--pad); display: grid; gap: 1rem; margin-bottom: 3rem; }
.filter__buttons { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.filter__btn {
  display: inline-flex; align-items: flex-start; gap: 0.35rem; min-height: 2.75rem;
  padding: 0.55rem 1.1rem; border: 1px solid var(--line); border-radius: 999px; background: none;
  font-family: var(--font-display); font-size: 0.875rem; font-weight: 500;
  transition: background-color 0.25s, color 0.25s, border-color 0.25s;
}
.filter__btn sup { font-size: 0.625rem; color: inherit; opacity: 0.6; line-height: 1; margin-top: 0.2rem; }
.filter__btn:hover { border-color: var(--fg); }
.filter__btn[aria-pressed='true'] { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.filter__status { font-size: 0.8125rem; color: var(--muted); }

.works-grid { display: grid; gap: clamp(3rem, 6vw, 5rem) var(--gap); padding-inline: var(--pad); }
.works-grid__empty { color: var(--muted); }
@media (min-width: 900px) {
  .works-grid { grid-template-columns: 1fr 1fr; column-gap: clamp(2rem, 5vw, 5rem); }
  .works-grid__item.is-offset { margin-top: clamp(4rem, 10vw, 9rem); }
  .works-grid.is-filtered .works-grid__item.is-offset { margin-top: 0; }
}

/* ---------- Work detail ---------- */
.work-head { display: grid; gap: 1.5rem; padding: calc(var(--header-h) + clamp(2rem, 6vw, 5rem)) var(--pad) clamp(2rem, 4vw, 3rem); }
.crumbs ol { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.crumbs li + li::before { content: '/'; margin-right: 0.5rem; opacity: 0.5; }
.crumbs a:hover { color: var(--fg); }
.work-head__title {
  font-family: var(--font-display); font-weight: 700; font-stretch: 125%;
  font-size: clamp(3rem, 13vw, 13rem); line-height: 0.85; letter-spacing: -0.05em;
  overflow-wrap: anywhere;
}
.work-head__sub { font-size: clamp(1.125rem, 1.8vw, 1.5rem); font-weight: 500; line-height: 1.5; max-width: 36rem; }
.work-meta { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem var(--gap); padding-top: 1.5rem; border-top: 1px solid var(--line); }
.work-meta div { display: flex; flex-direction: column; gap: 0.15rem; }
.work-meta dt { font-family: var(--font-display); font-size: 0.6875rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.work-meta dd { font-size: 0.875rem; font-weight: 500; }
@media (min-width: 900px) {
  .work-head { grid-template-columns: repeat(12, 1fr); }
  .work-head > * { grid-column: 1 / -1; }
  .work-head__sub { grid-column: 1 / span 6; }
  .work-meta { grid-template-columns: repeat(5, 1fr); }
}

.work-hero { padding-inline: var(--pad); }
.work-hero picture { aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--radius); background: var(--line); }
.work-hero__img { width: 100%; height: 100%; object-fit: cover; }

.overview { display: grid; gap: 2rem; }
.overview__body { display: grid; gap: 1.25rem; max-width: 44rem; }
.overview__summary { font-size: clamp(1.25rem, 2.2vw, 1.875rem); line-height: 1.6; font-weight: 500; text-wrap: pretty; }
.overview__label { margin-top: 1rem; font-size: 0.8125rem; color: var(--muted); font-weight: 500; }
.overview__body > p:last-child { color: var(--muted); }
@media (min-width: 900px) {
  .overview { grid-template-columns: repeat(12, 1fr); }
  .overview .section-title { grid-column: 1 / span 4; }
  .overview__body { grid-column: 5 / span 8; }
}

/* Editorial layout */
.ed-grid { display: grid; gap: 2.5rem var(--gap); margin-top: 3rem; }
.ed-item { display: grid; gap: 0.75rem; align-content: start; padding-top: 1.25rem; border-top: 1px solid var(--fg); }
.ed-item__title { font-size: 1.25rem; font-weight: 700; line-height: 1.45; }
.ed-item p { color: var(--muted); font-size: 0.9375rem; }
.ed-grid__media { overflow: hidden; border-radius: var(--radius); aspect-ratio: 4 / 3; }
@media (min-width: 900px) {
  .ed-grid { grid-template-columns: repeat(12, 1fr); }
  .ed-item:nth-child(1) { grid-column: 1 / span 4; }
  .ed-item:nth-child(2) { grid-column: 1 / span 4; }
  .ed-grid__media { grid-column: 6 / span 7; grid-row: 1 / span 3; aspect-ratio: 4 / 5; }
  .ed-item:nth-child(4) { grid-column: 1 / span 4; }
  .ed-item:nth-child(5) { grid-column: 6 / span 4; }
}

/* Screens layout (horizontal) */
.designed--screens { padding-top: var(--section); }
.hscroll__pin { padding-inline: var(--pad); }
.hscroll__title { margin-bottom: 2.5rem; }
.hscroll__track { display: grid; gap: 1rem; }
.hscroll__panel {
  display: flex; flex-direction: column; gap: 1rem;
  padding: 1.75rem; border-radius: var(--radius);
  background: color-mix(in srgb, var(--fg) 5%, var(--bg));
}
.hscroll__panel h3 { font-size: 1.25rem; font-weight: 700; line-height: 1.45; }
.hscroll__panel p:last-child { color: var(--muted); font-size: 0.9375rem; }
.hscroll__index { font-family: var(--font-display); font-weight: 600; font-stretch: 118%; font-size: 0.875rem; color: var(--accent); }
.hscroll__panel--media { padding: 0; overflow: hidden; }
.hscroll__panel--media img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 900px) {
  .motion .hscroll__pin { height: 100svh; display: flex; flex-direction: column; justify-content: center; overflow: hidden; }
  .motion .hscroll__track { display: flex; width: max-content; gap: 1.25rem; }
  .motion .hscroll__panel { width: min(26rem, 30vw); height: min(32rem, 58svh); justify-content: flex-end; }
  .motion .hscroll__panel .hscroll__index { margin-bottom: auto; font-size: clamp(3rem, 6vw, 5rem); line-height: 1; letter-spacing: -0.04em; }
  .motion .hscroll__panel--media { width: min(44rem, 48vw); }
  html:not(.motion) .hscroll__track { grid-template-columns: repeat(2, 1fr); }
}

/* Film layout */
.designed--film { padding-top: var(--section); }
.letterbox { padding-inline: var(--pad); }
.letterbox__frame { overflow: hidden; border-radius: var(--radius); aspect-ratio: 21 / 9; background: var(--ink); }
.letterbox__frame img { width: 100%; height: 100%; object-fit: cover; }
.motion .letterbox { height: 180svh; padding: 0; }
.motion .letterbox__frame {
  position: sticky; top: 0; height: 100svh; aspect-ratio: auto; border-radius: 0;
  clip-path: inset(30% 12% 30% 12%);
}
.chapters { margin-top: 3rem; counter-reset: ch; }
.chapter { display: grid; gap: 0.5rem 2rem; padding-block: 2rem; border-top: 1px solid var(--line); }
.chapter__tc { font-family: var(--font-display); font-weight: 600; font-stretch: 118%; font-size: 0.875rem; color: var(--accent); }
.chapter__title { font-size: clamp(1.25rem, 2vw, 1.625rem); font-weight: 700; line-height: 1.4; }
.chapter__text { color: var(--muted); max-width: 40rem; }
@media (min-width: 900px) {
  .chapter { grid-template-columns: 8rem 1fr 1.4fr; align-items: baseline; }
}

/* Space layout */
.designed--space { padding-top: var(--section); }
.depth { position: relative; overflow: hidden; }
.depth__back { aspect-ratio: 16 / 9; overflow: hidden; }
.depth__back img { width: 100%; height: 100%; object-fit: cover; }
.depth__front { position: absolute; inset: auto 0 0; padding-bottom: 2rem; color: var(--paper); }
.depth__front::before { content: ''; position: absolute; inset: -6rem 0 0; background: linear-gradient(transparent, color-mix(in srgb, var(--ink) 70%, transparent)); z-index: -1; }
.space-list { display: grid; gap: 0; overflow-x: clip; }
.space-item { display: grid; gap: 0.75rem 2rem; padding-block: 2rem; border-bottom: 1px solid var(--line); }
.space-item__title { font-family: var(--font-body); font-size: clamp(1.25rem, 2.4vw, 2rem); font-weight: 700; line-height: 1.35; }
.space-item p { color: var(--muted); max-width: 40rem; }
@media (min-width: 900px) {
  .space-item { grid-template-columns: 5fr 6fr; }
  .space-item:nth-child(even) { padding-left: 16.66%; }
}

/* Results, deliverables, credits */
.results__list { display: grid; gap: 0; margin-top: 3rem; border-top: 1px solid var(--line); }
.result { display: grid; gap: 0.5rem; padding-block: 1.75rem; border-bottom: 1px solid var(--line); }
.result__value {
  font-family: var(--font-display); font-weight: 700; font-stretch: 122%;
  font-size: clamp(3rem, 8vw, 7rem); line-height: 0.9; letter-spacing: -0.05em; color: var(--accent);
}
.result__label { color: var(--muted); max-width: 28rem; }
.results__note { margin-top: 1rem; font-size: 0.75rem; color: var(--muted); }
@media (min-width: 900px) {
  .results__list { grid-template-columns: repeat(3, 1fr); column-gap: var(--gap); }
  .result { padding-right: 1rem; }
}

.deliver { display: grid; gap: 3rem; }
.deliver__title { font-family: var(--font-display); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); font-weight: 500; margin-bottom: 1rem; }
.deliver__list li { padding-block: 0.65rem; border-bottom: 1px solid var(--line); font-weight: 500; }
.credits div { display: grid; grid-template-columns: 9rem 1fr; gap: 1rem; padding-block: 0.65rem; border-bottom: 1px solid var(--line); font-size: 0.9375rem; }
.credits dt { color: var(--muted); font-family: var(--font-display); font-size: 0.8125rem; }
@media (min-width: 900px) { .deliver { grid-template-columns: 1fr 1fr; gap: var(--gap); } }

.next-work { padding: var(--section) var(--pad) 0; }
.next-work a {
  display: grid; gap: 1rem; padding-top: 2rem; border-top: 1px solid var(--fg);
}
.next-work__title {
  font-family: var(--font-display); font-weight: 700; font-stretch: 125%;
  font-size: clamp(2.5rem, 9vw, 9rem); line-height: 0.9; letter-spacing: -0.05em;
  transition: color 0.25s;
}
.next-work a:hover .next-work__title { color: var(--accent); }
.next-work__media { display: block; width: min(24rem, 70%); aspect-ratio: 3 / 2; overflow: hidden; border-radius: var(--radius); }
@media (min-width: 900px) {
  .next-work a { grid-template-columns: 1fr auto; align-items: end; }
  .next-work .eyebrow { grid-column: 1 / -1; }
}

/* ---------- Journal index / article ---------- */
.journal-lead { padding-inline: var(--pad); }
.journal-lead a { display: grid; gap: 1.5rem; }
.journal-lead__media { aspect-ratio: 3 / 2; overflow: hidden; border-radius: var(--radius); }
.journal-lead__media img, .journal-card__media img, .article__media img { width: 100%; height: 100%; object-fit: cover; }
.journal-lead__text { display: grid; gap: 1rem; align-content: end; }
.journal-lead__title { font-size: clamp(1.5rem, 3vw, 2.5rem); line-height: 1.4; font-weight: 700; text-wrap: balance; transition: color 0.2s; }
.journal-lead a:hover .journal-lead__title { color: var(--accent); }
.journal-lead__text > p:not(.journal-meta) { color: var(--muted); }
@media (min-width: 900px) {
  .journal-lead a { grid-template-columns: 7fr 5fr; gap: clamp(2rem, 4vw, 4rem); }
}
.journal-cards { display: grid; gap: 3rem var(--gap); }
.journal-card a { display: grid; gap: 1rem; }
.journal-card__media { aspect-ratio: 16 / 10; overflow: hidden; border-radius: var(--radius); }
.journal-card__title { font-size: 1.25rem; font-weight: 700; line-height: 1.5; transition: color 0.2s; }
.journal-card a:hover .journal-card__title { color: var(--accent); }
.journal-card p:last-child { color: var(--muted); font-size: 0.9375rem; }
@media (min-width: 900px) {
  .journal-cards { grid-template-columns: 1fr 1fr; }
  .journal-card:nth-child(2) { margin-top: 6rem; }
}

.progress { position: fixed; inset: 0 0 auto; height: 2px; z-index: 50; pointer-events: none; }
.progress span { display: block; height: 100%; background: var(--accent); transform-origin: left; transform: scaleX(0); }

.article { padding-top: calc(var(--header-h) + clamp(2rem, 6vw, 5rem)); }
.article__head { display: grid; gap: 1.25rem; padding-inline: var(--pad); max-width: 60rem; }
.article__title { font-size: clamp(1.75rem, 4.4vw, 3.5rem); line-height: 1.35; font-weight: 700; letter-spacing: -0.01em; text-wrap: balance; }
.article__en { font-family: var(--font-display); font-stretch: 112%; font-weight: 500; color: var(--muted); }
.article__author { font-size: 0.875rem; }
.article__media { margin: clamp(2rem, 5vw, 4rem) var(--pad) 0; aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--radius); }
.article__body { padding: clamp(2.5rem, 6vw, 5rem) var(--pad) 0; max-width: calc(40rem + var(--pad) * 2); margin-inline: auto; display: grid; gap: 1.5rem; font-size: 1.0625rem; line-height: 2; }
.article__excerpt { font-size: 1.25rem; font-weight: 500; line-height: 1.8; }
.article__body h2 { margin-top: 2rem; font-size: 1.5rem; line-height: 1.5; font-weight: 700; }
.article__body blockquote { padding-left: 1.25rem; border-left: 2px solid var(--accent); font-size: 1.25rem; font-weight: 500; line-height: 1.8; }

/* ---------- Contact ---------- */
.contact { display: grid; gap: 4rem; padding-inline: var(--pad); }
.contact-form { display: grid; gap: 1.75rem; max-width: 40rem; }
.form-note { font-size: 0.8125rem; color: var(--muted); }
.demo-notice { display: grid; gap: 0.5rem; padding: 1.125rem 1.25rem; border: 1px solid var(--line); border-radius: var(--radius); font-size: 0.875rem; line-height: 1.7; color: var(--muted); }
.demo-notice__label { display: flex; align-items: center; gap: 0.75rem; color: var(--fg); font-weight: 700; font-size: 0.8125rem; }
.demo-notice__label span { padding: 0.125rem 0.5rem; border: 1px solid var(--accent); border-radius: 999px; color: var(--accent); font-family: var(--font-display); font-weight: 600; font-size: 0.6875rem; letter-spacing: 0.08em; text-transform: uppercase; }
.field { display: grid; gap: 0.5rem; border: 0; padding: 0; margin: 0; min-width: 0; }
.field > label, .field legend { font-size: 0.875rem; font-weight: 700; padding: 0; }
.field__hint { display: block; font-size: 0.8125rem; color: var(--muted); font-weight: 400; }
.field input:not([type='checkbox']), .field select, .field textarea {
  width: 100%; min-height: 3rem; padding: 0.75rem 0; background: transparent;
  border: 0; border-bottom: 1px solid var(--muted); border-radius: 0;
  font-size: 1rem; transition: border-color 0.2s;
}
.field textarea { resize: vertical; line-height: 1.7; }
.field select { appearance: none; background: linear-gradient(45deg, transparent 50%, currentColor 50%) calc(100% - 6px) 55% / 6px 6px no-repeat, linear-gradient(-45deg, transparent 50%, currentColor 50%) 100% 55% / 6px 6px no-repeat; padding-right: 1.5rem; }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: none; border-bottom: 2px solid var(--accent); }
.field.is-invalid input:not([type='checkbox']), .field.is-invalid textarea { border-bottom-color: #c4291c; }
.field__error { font-size: 0.8125rem; color: #c4291c; font-weight: 500; }
.field__error:empty { display: none; }
.choices { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.5rem; }
.choice { display: inline-flex; align-items: center; gap: 0.6rem; cursor: pointer; font-size: 0.9375rem; }
.choices .choice span { padding: 0.55rem 1rem; border: 1px solid var(--line); border-radius: 999px; transition: background-color 0.2s, color 0.2s, border-color 0.2s; }
.choices .choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choices .choice input:checked + span { background: var(--fg); color: var(--bg); border-color: var(--fg); }
.choices .choice input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.field > .choice input[type='checkbox'] { width: 1.25rem; height: 1.25rem; accent-color: var(--accent); }
.button {
  justify-self: start; display: inline-flex; align-items: center; gap: 1.5rem; min-height: 3.5rem;
  padding: 0 1.75rem; border: 0; border-radius: 999px; background: var(--fg); color: var(--bg);
  font-weight: 700; font-size: 0.9375rem; transition: background-color 0.25s;
}
.button:hover { background: var(--accent); color: var(--paper); }
.form-status:empty { display: none; }
.form-status { padding: 1.25rem; border: 1px solid var(--fg); border-radius: var(--radius); font-size: 0.9375rem; }
.form-status strong { display: block; margin-bottom: 0.25rem; }
.contact-aside { display: grid; gap: 2.5rem; align-content: start; }
.contact-block { display: grid; gap: 0.5rem; padding-top: 1.25rem; border-top: 1px solid var(--line); font-size: 0.9375rem; }
.contact-mail { font-family: var(--font-display); font-weight: 600; font-stretch: 112%; font-size: clamp(1.125rem, 2vw, 1.5rem); overflow-wrap: anywhere; }
.contact-mail:hover { color: var(--accent); }
.clock { font-family: var(--font-display); font-weight: 600; font-stretch: 118%; font-size: 2rem; line-height: 1; letter-spacing: -0.02em; }
.clock span { font-size: 0.75rem; font-weight: 500; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); font-stretch: 100%; }
@media (min-width: 900px) {
  .contact { grid-template-columns: repeat(12, 1fr); }
  .contact-form { grid-column: 1 / span 7; }
  .contact-aside { grid-column: 9 / span 4; }
}

/* ---------- Footer ---------- */
.site-footer {
  margin-top: var(--section);
  background: var(--bg); color: var(--fg);
  padding: clamp(4rem, 10vw, 8rem) var(--pad) 2rem;
  display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(4rem, 8vw, 6rem);
}
.footer-cta { display: grid; gap: 1.25rem; }
.footer-cta__link {
  display: inline-flex; align-items: baseline; gap: 0.15em; flex-wrap: wrap;
  font-family: var(--font-display); font-weight: 700; font-stretch: 125%;
  font-size: clamp(2.25rem, 10vw, 10rem); line-height: 0.9; letter-spacing: -0.05em;
  transition: color 0.3s;
}
.footer-cta__arrow { display: inline-block; transition: transform 0.6s var(--ease-out); }
.footer-cta__link:hover { color: var(--accent); }
.footer-cta__link:hover .footer-cta__arrow { transform: translateX(0.15em); }
.footer-cta__note { max-width: 30rem; color: var(--muted); font-size: 0.9375rem; }
.footer-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); overflow-wrap: anywhere; gap: 2.5rem var(--gap); font-size: 0.875rem; line-height: 1.8; }
.footer-heading { margin-bottom: 0.75rem; }
.footer-grid a:hover { color: var(--accent); }
.footer-links { display: grid; gap: 0.15rem; }
.footer-base { display: grid; gap: 1rem; padding-top: 1.5rem; border-top: 1px solid var(--line); font-size: 0.75rem; color: var(--muted); }
.demo-note { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; }
.demo-note a { text-decoration: underline; text-underline-offset: 0.2em; }
.demo-note a:hover { color: var(--fg); }
@media (min-width: 900px) {
  .footer-grid { grid-template-columns: repeat(4, 1fr); }
  .footer-base { grid-template-columns: auto 1fr; }
  .demo-note { justify-content: flex-end; }
}

/* ---------- 404 ---------- */
.notfound { min-height: 70svh; align-content: center; }

/* ---------- View Transitions (work card ↔ work hero only) ---------- */
@view-transition { navigation: auto; }
::view-transition-group(work-media) { animation-duration: 0.7s; animation-timing-function: cubic-bezier(0.7, 0, 0.2, 1); }
::view-transition-old(root),
::view-transition-new(root) { animation-duration: 0.35s; }

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

/* Responsive typography: preserve words, allow grid children to shrink. */
:where(main, section, article, figure, .grid) > * { min-width: 0; }
:where(h1, h2, h3) { line-break: strict; }
:where(p, li, dd, figcaption) { line-break: strict; }
:where(h1, h2, h3):lang(ja) { word-break: auto-phrase; overflow-wrap: anywhere; }
:where(p, figcaption):lang(ja) { text-wrap: pretty; }

.hero__title { font-size: clamp(2rem, 6.8vw, 7rem); line-height: 1.04; }
.hero__title .line { overflow: visible; }
.hero__title .line__inner { min-width: 0; }
.hero-phrase { display: inline-block; }
.hero__title .line:last-child .line__inner { display: flex; flex-wrap: wrap; gap: 0 0.2em; }
.work-card__media { aspect-ratio: 4 / 3; }
.selected__item--1 .work-card__media, .selected__item--2 .work-card__media { aspect-ratio: 4 / 3; }
@media (max-width: 47.99rem) {
  .hero .hero__title { font-size: clamp(1.75rem, 8.6vw, 3.5rem); line-height: 1.08; }
  .hero__title .line__inner { overflow-wrap: normal; }
  .page-title { font-size: clamp(2rem, 8vw, 3.75rem); line-height: 1.08; }
  .article__title { font-size: clamp(1.5rem, 6.3vw, 2rem); line-height: 1.5; }
}
.hero { min-height: auto; grid-template-rows: auto auto auto; gap: clamp(2.5rem, 4vw, 4rem); }

:where(p, li, dd, figcaption):lang(ja) { word-break: auto-phrase; overflow-wrap: anywhere; }
