/* AsWork company site. Flat, light, with the colour concentrated in the brand motif. */
:root {
  --ink: #111114;
  --paper: #f7f7f5;
  --line: #d8d8d4;
  --muted: #5f5f64;
  --dark-muted: #a1a1a7;
  --gutter: 5.2vw;
  --head: 96px;
  --foot: 78px;
  --rainbow: linear-gradient(90deg, #ff8515, #ff009c, #6700ff, #002dff, #00dfdd);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 24px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Arial, 'Helvetica Neue', 'Hiragino Sans', 'Noto Sans JP', sans-serif;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; }
ul { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 2px solid #5a19ff; outline-offset: 6px; }
::selection { background: #d4ff5a; color: var(--ink); }
.defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.sr-only {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.wrap { max-width: 1600px; margin: 0 auto; padding: 0 var(--gutter); }

/* Header */
.site-head {
  height: var(--head);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: space-between;
  position: relative; z-index: 5;
}
.brand { display: inline-flex; align-items: center; min-height: 44px; }
.brand-logo { width: 286px; height: 44px; display: block; }
.nav { display: flex; align-items: center; gap: 34px; font-size: 14px; letter-spacing: .04em; }
.nav a { padding: 12px 0; transition: opacity .2s; }
.nav a:hover { opacity: .5; }
.nav .nav-contact { padding: 13px 19px; border: 1px solid #a8a8a8; border-radius: 30px; transition: background-color .2s, color .2s, border-color .2s; }
.nav .nav-contact:hover { opacity: 1; background: var(--ink); color: var(--paper); border-color: var(--ink); }
.menu { display: none; background: none; border: 0; padding: 12px 0 12px 20px; font-size: 13px; letter-spacing: .1em; }
.menu-close { display: none; }
.menu[aria-expanded='true'] .menu-open { display: none; }
.menu[aria-expanded='true'] .menu-close { display: inline; }

/* Hero */
.hero {
  position: relative; overflow: hidden; isolation: isolate;
  min-height: 760px; height: calc(100svh - var(--head)); max-height: 1020px;
}
.hero-mark { position: absolute; top: 45px; left: var(--gutter); width: min(40%, 560px); margin: 0; line-height: 1; pointer-events: none; z-index: 2; }
.hero-mark svg { display: block; width: 100%; height: auto; aspect-ratio: 1418 / 192; }
/* The field ends at the foot rule. site.js clears soft spaces round the wordmark and the business line, so text never sits on colour. */
.art-field { position: absolute; inset: 0 0 var(--foot) 0; z-index: -1; overflow: hidden; pointer-events: none; }
/* The lines are drawn by site.js: geometric bands in the brand spectrum, turning through each other across the hero, with pulses running along them. */
.art-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; pointer-events: auto; touch-action: pan-y; cursor: grab; }
.art-canvas.turning, .art-canvas.pulling { cursor: grabbing; }
/* An invisible handle over the free end of the thread: it takes touch and keyboard, so the rest of the hero still scrolls. */
.thread-tip {
  position: absolute; top: 0; left: 0; z-index: 1; width: 48px; height: 48px; padding: 0;
  border: 0; border-radius: 50%; background: transparent; touch-action: none; cursor: grab;
}
.thread-tip:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }

.hero-copy {
  position: absolute; left: var(--gutter); bottom: 93px;
}
.hero-business { font-size: 16px; letter-spacing: .07em; font-weight: 500; margin: 0; }
.round-link { display: inline-flex; align-items: center; gap: 17px; font-size: 14px; min-height: 44px; }
.hero-copy .round-link { margin-top: 8px; }
.circle {
  display: grid; place-items: center; width: 37px; height: 37px;
  border: 1px solid #999; border-radius: 50%; font-size: 18px;
  transition: background-color .2s, color .2s, transform .2s, border-color .2s;
}
.round-link:hover .circle, .contact-mail:hover .circle { background: var(--ink); color: var(--paper); border-color: var(--ink); transform: rotate(-45deg); }
.hero-foot {
  position: absolute; left: var(--gutter); right: var(--gutter); bottom: 23px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  border-top: 1px solid #c8c8c8; padding: 10px 0 4px;
  font-size: 12px; letter-spacing: .1em;
}
.motion { border: 0; background: none; font-size: 12px; letter-spacing: .1em; padding: 10px 0 10px 12px; min-height: 40px; }
.motion-on { display: none; }
.motion[aria-pressed='true'] .motion-off { display: none; }
.motion[aria-pressed='true'] .motion-on { display: inline; }

/* Sections */
.section { padding: 110px 0; border-top: 1px solid var(--line); }
.section-head { font-size: 13px; letter-spacing: .15em; margin-bottom: 63px; }
.section-head b { margin-right: 45px; font-weight: 700; }

.services-title { font-size: clamp(48px, 7vw, 108px); font-weight: 400; letter-spacing: -.065em; line-height: 1.05; margin: 0 0 60px; }
.service-row {
  display: grid; grid-template-columns: 60px 1.1fr 1fr; gap: 25px;
  padding: 42px 0; border-top: 1px solid var(--line); align-items: start;
}
.service-no { font-size: 15px; padding-top: 10px; }
.service-row h3 { font-size: 35px; letter-spacing: -.04em; margin: 0 0 14px; font-weight: 400; }
.service-row .jp { font-size: 14px; color: var(--muted); letter-spacing: .08em; }
.service-row p { font-size: 15px; line-height: 2; margin: 5px 0 18px; }
.tags { display: flex; gap: 8px; flex-wrap: wrap; }
.tags li { font-size: 12px; letter-spacing: .06em; border: 1px solid #c7c7c7; border-radius: 20px; padding: 7px 10px; }

.work { background: #eaeae7; }
.work-title { font-size: 65px; font-weight: 400; letter-spacing: -.06em; line-height: 1.1; margin: 0 0 40px; }
.work-card { display: grid; grid-template-columns: 1.15fr 1fr; background: #f8f8f5; min-height: 460px; }
.work-visual {
  position: relative; min-height: 410px; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background: #e3e6dc;
}
.work-visual img { width: 65%; height: auto; display: block; }
.work-detail { padding: 60px 13%; }
.small { font-size: 12px; letter-spacing: .15em; }
.work-detail h3 { font-size: 34px; font-weight: 400; letter-spacing: -.025em; margin: 35px 0 20px; }
.work-detail p { font-size: 16px; line-height: 2.1; color: #4a4a4c; margin: 0; }
.work-detail .round-link { margin-top: 30px; }
.art-strip { margin: 24px 0 0; }
.art-strip ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.art-strip li { background: #f8f8f5; aspect-ratio: 3 / 4; overflow: hidden; }
.art-strip img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .6s cubic-bezier(.2,.7,.2,1); }
.art-strip li:hover img { transform: scale(1.04); }
.art-strip figcaption { margin-top: 14px; color: var(--muted); }
@media (max-width: 800px) {
  .art-strip ul { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 44%; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; }
  .art-strip li { scroll-snap-align: start; }
}
@media (prefers-reduced-motion: reduce) { .art-strip img { transition: none; } .art-strip li:hover img { transform: none; } }

/* Contact and company (dark) */
.dark { background: var(--ink); color: #f8f8f5; position: relative; }
.dark::before { content: ''; position: absolute; inset: 0 0 auto; height: 5px; background: var(--rainbow); }
.dark :focus-visible { outline-color: #9ee7ff; }
.contact { padding: 80px 0 0; }
.contact .section-head { margin-bottom: 65px; }
.contact-title { font-size: clamp(70px, 13vw, 185px); font-weight: 400; letter-spacing: -.07em; line-height: 1; margin: 0; }
.contact-bottom { display: flex; justify-content: space-between; align-items: center; gap: 24px; padding: 35px 0 70px; }
.contact-bottom p { font-size: 16px; line-height: 2; margin: 0; }
.contact-mail { display: inline-flex; align-items: center; gap: 24px; font-size: clamp(20px, 2.2vw, 30px); min-height: 55px; overflow-wrap: anywhere; }
.contact-mail .circle { width: 55px; height: 55px; flex: none; border-color: #77777e; }
.contact-mail:hover .circle { background: #f8f8f5; color: var(--ink); border-color: #f8f8f5; }
.company { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; border-top: 1px solid #37373c; padding-top: 35px; padding-bottom: 50px; }
.company-mark { width: 160px; height: 22px; display: block; }
.company-name { font-size: 15px; letter-spacing: .06em; margin: 15px 0 0; }
.company dl { display: grid; grid-template-columns: 110px 1fr; font-size: 15px; gap: 14px; margin: 0; line-height: 1.8; }
.company dt { color: var(--dark-muted); }
.company dd { margin: 0; }
  .company dd a { display: inline-block; padding: 10px 0; margin: -10px 0; text-decoration: underline; text-underline-offset: 4px; text-decoration-color: #77777e; transition: text-decoration-color .2s; }
.company dd a:hover { text-decoration-color: currentColor; }
.legal {
  border-top: 1px solid #37373c; padding-top: 14px; padding-bottom: 14px;
  display: flex; justify-content: space-between; align-items: center;
  font-size: 12px; color: var(--dark-muted); letter-spacing: .08em;
}
.legal a { padding: 14px 0; transition: color .2s; }
.legal a:hover { color: #f8f8f5; }

@media (min-width: 1650px) {
  .hero { height: 900px; }
  .hero-mark, .hero-copy { left: calc((100vw - 1600px) / 2 + 83px); }
}

@media (max-width: 800px) {
  :root { --gutter: 6vw; --head: 76px; }
  .brand-logo { width: 247px; height: 38px; }
  .nav { gap: 19px; font-size: 13px; }
  .nav .nav-contact { padding: 10px 14px; }
  .hero { min-height: 660px; max-height: 950px; }
  .hero-mark { top: 38px; width: 58%; }
  .hero-copy { bottom: 98px; }
  .hero-business { font-size: 15px; }
  .hero-company { display: none; }
  .section { padding: 70px 0; }
  .section-head { margin-bottom: 40px; }
  .section-head b { margin-right: 24px; }
  .services-title { font-size: 64px; margin-bottom: 35px; }
  .service-row { grid-template-columns: 25px 1fr; gap: 14px; padding: 28px 0; }
  .service-row h3 { font-size: 30px; }
  .service-desc { grid-column: 2; }
  .work-title { font-size: 51px; }
  .work-card { grid-template-columns: 1fr; }
  .work-visual { min-height: 300px; }
  .work-detail { padding: 35px; }
  .work-detail h3 { margin-top: 22px; font-size: 30px; }
  .contact { padding-top: 60px; }
  .contact-bottom { display: block; padding: 25px 0 45px; }
  .contact-mail { margin-top: 24px; font-size: 23px; }
  .company { grid-template-columns: 1fr; gap: 35px; }
}

@media (max-width: 520px) {
  .menu { display: block; }
  .brand-logo { width: 208px; height: 32px; }
  .nav {
    display: none; position: absolute; top: calc(var(--head) - 1px); left: calc(-1 * var(--gutter)); right: calc(-1 * var(--gutter));
    flex-direction: column; align-items: flex-start; gap: 4px;
    padding: 18px var(--gutter) 26px; background: var(--paper); border-bottom: 1px solid var(--line);
    font-size: 15px;
  }
  .nav.open { display: flex; }
  .nav a { padding: 12px 0; }
  .nav .nav-contact { margin-top: 10px; padding: 12px 20px; }
  .hero { min-height: 600px; max-height: 830px; }
  .hero-mark { top: 36px; width: 64%; }
  .hero-copy { bottom: 92px; }
  .services-title { font-size: 13vw; }
  .service-row h3 { font-size: 27px; }
  .work-title { font-size: 45px; }
  .work-visual { min-height: 240px; }
  .work-detail { padding: 30px 24px 36px; }
  .work-detail h3 { font-size: 26px; }
  .contact-title { font-size: 18vw; }
  .contact-mail { font-size: 21px; gap: 18px; }
  .company dl { grid-template-columns: 92px 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .circle, .nav a, .legal a { transition: none; }
}

/* ── Motion layer: the colour motif carries the page. Transforms and opacity only, nothing hides without JS. ── */
:root { --p: 0; --q: 0; --mx: 0; --my: 0; --spectrum: linear-gradient(100deg, #ff9814 0%, #ff1882 22%, #e000ef 42%, #5c00ff 61%, #0038ff 79%, #00e6df 100%); }

.art-move { position: absolute; inset: 0; }
.hero-mark.draw svg { animation: draw 1.3s cubic-bezier(.65, 0, .35, 1) both; }
@keyframes draw { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }

/* The spectrum band: the brand gradient as type, moving. */
.spectrum {
  overflow: hidden; border-top: 1px solid var(--line);
  padding: 34px 0 30px; white-space: nowrap; user-select: none;
}
.spectrum-track {
  display: inline-flex; align-items: center; gap: .32em;
  font-size: clamp(64px, 11vw, 190px); font-weight: 400; letter-spacing: -.06em; line-height: 1;
  animation: band 38s linear infinite; will-change: transform;
}
.spectrum-track span {
  background: var(--spectrum); background-size: 100% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  padding: 0 .02em .08em;
}
.spectrum-track i { width: .2em; height: .2em; border-radius: 50%; background: var(--ink); flex: none; }
@keyframes band { to { transform: translate3d(-50%, 0, 0); } }

/* Headings fill with the spectrum as they arrive. */
.spectrum-text {
  background: linear-gradient(100deg, var(--ink) 0 37%, #ff9814 40%, #ff1882 44%, #e000ef 48%, #5c00ff 52%, #0038ff 56%, #00e6df 60%, var(--ink) 63% 100%);
  background-size: 260% 100%; background-position: 100% 0;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  padding-bottom: .06em;
}
.js .spectrum-text.in { animation: sweep 1.8s cubic-bezier(.6, 0, .2, 1) .2s both; }
@keyframes sweep { from { background-position: 100% 0; } to { background-position: 0 0; } }

/* Rules draw themselves in the spectrum. */
.service-row, .work-card { position: relative; }
.service-row::before, .work-card::before {
  content: ''; position: absolute; left: 0; right: 0; top: -1px; height: 2px;
  background: var(--spectrum); transform: scaleX(0); transform-origin: left;
  transition: transform 1.1s cubic-bezier(.65, 0, .35, 1) .15s;
}
.work-card::before { height: 4px; top: 0; z-index: 1; }
.no-js .service-row::before, .no-js .work-card::before, .in.service-row::before, .in.work-card::before { transform: scaleX(1); }
.service-row:hover h3 { background: var(--spectrum); -webkit-background-clip: text; background-clip: text; color: transparent; }
.service-no { background: var(--spectrum); -webkit-background-clip: text; background-clip: text; color: transparent; font-weight: 700; }

/* Arrivals. */
.js [data-reveal] { opacity: 0; transform: translate3d(0, 34px, 0); transition: opacity .9s ease, transform 1s cubic-bezier(.2, .7, .2, 1); }
.js [data-reveal].in { opacity: 1; transform: none; }

/* Links: the spectrum underneath. */
.nav a:not(.nav-contact) { position: relative; }
.nav a:not(.nav-contact)::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 6px; height: 2px;
  background: var(--spectrum); transform: scaleX(0); transform-origin: left; transition: transform .3s ease;
}
.nav a:not(.nav-contact):hover { opacity: 1; }
.nav a:not(.nav-contact):hover::after { transform: scaleX(1); }
.nav .nav-contact:hover { background: var(--spectrum); border-color: transparent; color: #fff; }
.round-link:hover .circle { background: var(--spectrum); border-color: transparent; color: #fff; }

/* Contact: the motif on black, turning as it scrolls by. */
.contact { position: relative; overflow: hidden; isolation: isolate; }
.contact-art {
  position: absolute; z-index: -1; pointer-events: none;
  top: 0; bottom: 0; left: 42%; right: -18%;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 22%);
  mask-image: linear-gradient(90deg, transparent 0, #000 22%);
}
.contact-move {
  position: absolute; inset: 6% 0;
  transform: translate3d(calc(var(--q) * -6%), 0, 0) rotate(calc(-14deg + var(--q) * 18deg)) scale(calc(1.05 + var(--q) * .15));
  transform-origin: 50% 50%; will-change: transform;
}
.contact-move img { width: 100%; height: 100%; object-fit: contain; display: block; }
.contact-bottom { display: block; padding-top: 30px; }
.contact-bottom p { margin-bottom: 22px; }
.contact-mail:hover .circle { background: var(--spectrum); color: #fff; border-color: transparent; }

@media (max-width: 800px) {
  .spectrum { padding: 22px 0 20px; }
  .contact-art { left: -10%; right: -40%; top: 52px; bottom: auto; height: 240px; -webkit-mask-image: none; mask-image: none; }
  .contact .section-head { margin-bottom: 250px; }
}

/* Paused or reduced: everything holds still and visible. */
.paused .contact-move { transform: none; }
.paused .contact-move { transform: rotate(-14deg) scale(1.05); }
.paused .spectrum-track { animation-play-state: paused; }
@media (prefers-reduced-motion: reduce) {
  .contact-move { transform: none !important; }
  .contact-move { transform: rotate(-14deg) scale(1.05) !important; }
  .spectrum-track, .hero-mark.draw svg, .js .spectrum-text.in { animation: none; }
  .spectrum-text { background-position: 0 0; }
  .js [data-reveal] { opacity: 1; transform: none; transition: none; }
  .service-row::before, .work-card::before { transform: scaleX(1); transition: none; }
}
