:root {
  --black: #000000;
  --ink: #d4d2cc;
  --muted: #77756f;
  --accent: #9a9a9a;
  --seal: #a8362c;
  --line: rgba(154, 154, 154, .22);
  font-family: 'Manrope', sans-serif;
  color: var(--ink);
  background: var(--black);
}

* { box-sizing: border-box; }
html, body { margin: 0; min-width: 320px; background: var(--black); }
html { overflow-x: hidden; }
html { scroll-behavior: smooth; }
body { overflow-x: hidden; }
a { color: inherit; text-decoration: none; }
img { display: block; }

.skip-link { position: fixed; top: 12px; left: 12px; z-index: 200; padding: 12px 16px; background: var(--ink); color: var(--black); font-size: 12px; transform: translateY(-160%); transition: transform .2s; }
.skip-link:focus { transform: none; }

.loader {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: none;
}
html.js .loader { display: block; }
.loader.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.loader::before, .loader::after { content: ''; position: absolute; z-index: 0; left: 0; right: 0; height: 50%; background: var(--black); transition: transform 1.1s cubic-bezier(.76, 0, .24, 1); }
.loader::before { top: 0; }
.loader::after { bottom: 0; }
.loader.is-leaving::before { transform: translateY(-100%); }
.loader.is-leaving::after { transform: translateY(100%); }
.loader > * { z-index: 1; transition: opacity .45s ease; }
.loader.is-leaving > * { opacity: 0; }
.loader.is-leaving .loader__top { animation: none; }
.loader__top { position: absolute; top: 28px; right: 4.2vw; left: 4.2vw; display: flex; justify-content: space-between; align-items: center; color: var(--muted); font-size: 10px; letter-spacing: .17em; text-transform: uppercase; opacity: 0; animation: loader-fade .8s ease forwards .2s; }
.loader__brand { color: var(--ink); font-size: 14px; font-weight: 700; letter-spacing: .26em; }
.loader__stamp { position: absolute; top: 50%; left: 50%; display: grid; place-items: center; width: 92px; height: 92px; margin: -46px 0 0 -46px; border: 2px solid var(--seal); color: var(--seal); font-family: 'Zen Old Mincho', serif; font-size: 30px; line-height: 1; writing-mode: vertical-rl; letter-spacing: .04em; opacity: 0; transform: scale(2.2) rotate(-12deg); animation: stamp .6s cubic-bezier(.2, .9, .3, 1.15) .15s forwards; }
.loader__stamp::before { content: ''; position: absolute; inset: 5px; border: 1px solid rgba(168, 54, 44, .55); }
.loader__name { position: absolute; top: calc(50% + 86px); right: 0; left: 0; margin: 0; text-align: center; color: var(--ink); font-size: clamp(26px, 3.6vw, 48px); font-weight: 700; letter-spacing: .42em; text-indent: .42em; }
.loader__name span { display: inline-block; opacity: 0; transform: translateY(70%); filter: blur(6px); animation: letter-in .9s cubic-bezier(.16, 1, .3, 1) forwards; animation-delay: calc(.85s + var(--i) * .08s); }
.loader__count { position: absolute; right: 4.2vw; bottom: calc(8vh + 18px); color: var(--ink); font-size: 11px; letter-spacing: .24em; font-variant-numeric: tabular-nums; }
.loader__bar { position: absolute; right: 4.2vw; bottom: 8vh; left: 4.2vw; height: 1px; background: rgba(154, 154, 154, .2); }
.loader__bar i { display: block; height: 100%; background: var(--ink); transform: scaleX(0); transform-origin: left; }
.loader__bar b { position: absolute; top: 50%; left: calc(var(--p, 0) * 100%); width: 7px; height: 7px; margin: -3.5px 0 0 -3.5px; border-radius: 50%; background: var(--seal); }
@keyframes stamp { to { opacity: 1; transform: scale(1) rotate(-4deg); } }
@keyframes letter-in { to { opacity: 1; transform: none; filter: blur(0); } }
@keyframes loader-fade { to { opacity: 1; } }

.topbar {
  position: fixed;
  z-index: 40;
  top: 0;
  right: 0;
  left: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 28px 4.2vw;
  font-size: 10px;
  letter-spacing: .17em;
  text-transform: uppercase;
  transition: transform .5s cubic-bezier(.16, 1, .3, 1), background-color .45s ease, border-color .45s ease;
  border-bottom: 1px solid transparent;
}
.topbar.is-scrolled { background: rgba(4, 4, 4, .78); border-bottom-color: var(--line); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.topbar.is-up { transform: translateY(-100%); }
.wordmark { font-size: 14px; font-weight: 700; letter-spacing: .26em; }
.topbar__link { padding: 9px 12px; border: 1px solid rgba(154, 154, 154, .5); color: var(--ink); transition: border-color .25s ease; }
.topbar__link:hover { border-color: var(--ink); }
.topbar__link span { color: var(--accent); }
.topbar__nav { display: flex; gap: 40px; }
.topbar__nav a { position: relative; padding: 6px 0; color: #a3a3a0; transition: color .25s ease; }
.topbar__nav a::after { content: ''; position: absolute; right: 0; bottom: 0; left: 0; height: 1px; background: var(--ink); transform: scaleX(0); transform-origin: right; transition: transform .45s cubic-bezier(.16, 1, .3, 1); }
.topbar__nav a:hover { color: var(--ink); }
.topbar__nav a:hover::after { transform: scaleX(1); transform-origin: left; }

.eyebrow { margin: 0; color: var(--muted); font-size: 10px; letter-spacing: .2em; text-transform: uppercase; }
.eyebrow span { margin-right: 18px; color: var(--accent); }
.section-title { margin: 0; color: var(--ink); font-size: clamp(52px, 8vw, 118px); font-weight: 700; line-height: .86; letter-spacing: -.07em; }
.section-title em { color: #777774; font-style: normal; font-weight: 400; }
.split .line { display: block; overflow: hidden; }
html.js .split .line > span { display: block; transform: translateY(110%); transition: transform 1s cubic-bezier(.16, 1, .3, 1); transition-delay: var(--d, 0s); }
html.js .split .line:nth-child(2) > span { transition-delay: calc(var(--d, 0s) + .12s); }
html.js .split.is-revealed .line > span { transform: none; }

html.js [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .9s ease, transform 1s cubic-bezier(.16, 1, .3, 1); }
html.js [data-reveal].is-revealed { opacity: 1; transform: none; }

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  overflow: hidden;
  isolation: isolate;
}
.hero__text { position: absolute; z-index: 3; top: 50%; left: 8vw; max-width: 760px; transform: translateY(-50%); }
.hero .eyebrow { margin-bottom: 26px; }
.hero h1 { margin: 0; font-size: clamp(72px, 13vw, 210px); font-weight: 700; line-height: .84; letter-spacing: -.07em; }
.hero h1 .line { padding-bottom: .04em; }
.hero h1 em { color: #999995; font-style: normal; font-weight: 400; }
.hero__lead { max-width: 380px; margin: 34px 0 0 4px; color: #a3a3a0; font-size: 15px; line-height: 1.7; }
.hero__image {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 1;
  width: min(54vw, 820px);
  height: 100%;
  background: linear-gradient(90deg, var(--black) 0%, transparent 28%), linear-gradient(0deg, var(--black) 0%, transparent 16%), url('assets/works/samurai-back.jpg') center / cover no-repeat;
  opacity: .9;
}
html.js .hero__image { transform: scale(1.12); transition: transform 1.8s cubic-bezier(.16, 1, .3, 1); }
html.js .hero__image.is-settled { transform: none; }
.hero__seal {
  position: absolute;
  z-index: 4;
  top: 16vh;
  right: 6vw;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid var(--seal);
  color: var(--seal);
  font-family: 'Zen Old Mincho', serif;
  font-size: 13px;
  line-height: 1;
  writing-mode: vertical-rl;
  letter-spacing: .08em;
}
.hero__footer { position: absolute; z-index: 4; right: 4.2vw; bottom: 34px; left: 8vw; display: flex; align-items: center; gap: 18px; color: var(--muted); font-size: 9px; letter-spacing: .18em; text-transform: uppercase; }
.scroll-line { display: block; width: 64px; height: 1px; background: var(--accent); }
.hero__footer span:last-child { margin-left: auto; }



.section-head { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 28px; margin-bottom: 7vh; }
.section-head .eyebrow { white-space: nowrap; }
.section-rule { display: block; height: 1px; background: rgba(154, 154, 154, .28); }

.gallery { padding: 14vh 4vw 16vh; }
.gallery .section-head, .gallery .section-title { max-width: 1200px; margin-left: auto; margin-right: auto; }
.gallery .section-title { margin-bottom: 8vh; }
.gallery__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; margin: 0 -4vw; }
.gallery__item { position: relative; margin: 0; padding: 1cm; aspect-ratio: 3 / 4; border: 1px solid var(--line); background: #070707; }
.gallery__item img { width: 100%; height: 100%; object-fit: cover; cursor: zoom-in; transition: filter .6s ease, border-color .6s ease; filter: saturate(.9) contrast(1.04); }
.gallery__item:hover { border-color: rgba(203, 203, 203, .4); }
.gallery__item:hover img { filter: saturate(1) contrast(1.08); }
.gallery__item img:focus-visible { outline: 1px solid var(--accent); outline-offset: 4px; }
.gallery__item figcaption { position: absolute; right: 1cm; bottom: .35cm; left: 1cm; display: flex; gap: 14px; color: #8c8a84; font-size: 9px; letter-spacing: .16em; text-transform: uppercase; pointer-events: none; }
.gallery__item figcaption span { color: var(--accent); }
.gallery .section-head { grid-template-columns: auto 1fr auto; }
.section-count { color: var(--accent); }

.about { padding: 14vh 4vw 16vh; border-top: 1px solid var(--line); background: #050505; }
.about__body { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 8vw; max-width: 1180px; margin: 0 auto; align-items: start; }
.about__portrait { margin: 0; overflow: hidden; background: #111; }
.about__portrait img { width: 100%; height: auto; filter: grayscale(1) contrast(1.05); }
.about__text { padding-top: 4vh; }
.about__text .section-title { margin-bottom: 6vh; }
.about__text p { max-width: 520px; margin: 0 0 18px; color: #a3a3a0; font-size: 16px; line-height: 1.8; }
.about__text p + p { margin-top: 0; }
.about__subtitle { margin: 6vh 0 18px; color: var(--accent); font-size: 10px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; }
.about__steps { display: grid; gap: 0; max-width: 520px; margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.about__steps li { display: flex; gap: 18px; padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--ink); font-size: 14px; }
.about__steps span { color: var(--accent); font-size: 11px; letter-spacing: .14em; padding-top: 2px; }
.about__facts { display: grid; gap: 0; max-width: 520px; margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.about__facts li { padding: 14px 0; border-bottom: 1px solid var(--line); color: #a3a3a0; font-size: 14px; line-height: 1.55; }
.about__facts strong { display: block; margin-bottom: 4px; color: var(--ink); font-size: 10px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; }
.about__cta { max-width: 520px; margin-top: 7vh; padding-top: 28px; border-top: 1px solid var(--line); }
.about__cta p { margin: 0 0 22px; }
.about__link { display: inline-flex; align-items: center; gap: 8px; padding: 14px 20px; border: 1px solid var(--ink); color: #050505; background: var(--ink); font-size: 10px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; transition: color .25s ease, background-color .25s ease; }
.about__link span { font-size: 12px; }
.about__link:hover { color: var(--ink); background: transparent; }

.contacts { padding: 14vh 4vw 18vh; border-top: 1px solid var(--line); background: #000; }
.contacts__body { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(260px, .8fr); gap: 8vw; max-width: 1180px; margin: 0 auto; align-items: end; }
.contacts .section-title { margin: 0; font-size: clamp(42px, 5.2vw, 80px); letter-spacing: -.09em; line-height: .87; hyphens: auto; }
.contacts .section-title em { padding: .12em .04em .22em; color: transparent; font-weight: 400; background: linear-gradient(110deg, #f0f0f0 5%, #8caf9f 48%, #367362 100%); -webkit-background-clip: text; background-clip: text; }
.contacts__info { display: grid; gap: 14px; }
.contacts__caption { margin: 18px 0 0; color: var(--muted); font-size: 10px; letter-spacing: .2em; text-transform: uppercase; }
.contacts__caption:first-child { margin-top: 0; }
.contacts__links { display: flex; flex-wrap: wrap; gap: 14px 26px; }
.contacts__links a { padding-bottom: 6px; border-bottom: 1px solid rgba(154, 154, 154, .48); color: var(--ink); font-size: 14px; letter-spacing: .04em; transition: border-color .25s ease; }
.contacts__links a:hover { border-color: var(--ink); }
.contacts__cta { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 26px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); color: var(--ink); font-size: clamp(30px, 3.6vw, 52px); font-weight: 600; letter-spacing: -.04em; transition: padding .5s cubic-bezier(.16, 1, .3, 1), color .3s ease; }
.contacts__cta-arrow { color: var(--seal); font-weight: 300; transition: transform .5s cubic-bezier(.16, 1, .3, 1); }
.contacts__cta:hover { padding-left: 14px; color: #fff; }
.contacts__cta:hover .contacts__cta-arrow { transform: translate(4px, -4px); }
.contacts__cta:focus-visible, .contacts__links a:focus-visible, .contacts__address:focus-visible, .site-footer__links a:focus-visible, .topbar__nav a:focus-visible { outline: 1px solid var(--accent); outline-offset: 6px; }
.contacts__links a span, .contacts__address span { color: var(--accent); }
.contacts__address { color: var(--ink); font-size: 15px; line-height: 1.7; }

.site-footer { padding: 56px 4.2vw 30px; border-top: 1px solid var(--line); color: var(--muted); font-size: 9px; letter-spacing: .17em; text-transform: uppercase; }
.site-footer__top { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 28px; padding-bottom: 44px; }
.site-footer .wordmark { color: var(--ink); font-size: clamp(28px, 4vw, 48px); letter-spacing: .2em; }
.site-footer__links { display: flex; gap: 32px; flex-wrap: wrap; }
.site-footer__links a { position: relative; color: #a3a3a0; padding-bottom: 4px; transition: color .25s ease; }
.site-footer__links a::after { content: ''; position: absolute; right: 0; bottom: 0; left: 0; height: 1px; background: var(--ink); transform: scaleX(0); transform-origin: right; transition: transform .45s cubic-bezier(.16, 1, .3, 1); }
.site-footer__links a:hover { color: var(--ink); }
.site-footer__links a:hover::after { transform: scaleX(1); transform-origin: left; }
.site-footer__bottom { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding-top: 22px; border-top: 1px solid var(--line); }

.lightbox { position: fixed; inset: 0; z-index: 60; display: grid; grid-template-columns: 80px minmax(0, 1fr) 80px; align-items: center; padding: 54px 5vw 36px; background: rgba(0, 0, 0, .96); opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .35s ease, visibility .35s ease; }
.lightbox.is-open { opacity: 1; visibility: visible; pointer-events: auto; }
.lightbox__figure { position: relative; display: flex; flex-direction: column; width: min(78vw, 920px); height: min(86vh, 940px); margin: auto; }
.lightbox__image { flex: 1; min-height: 0; width: 100%; object-fit: contain; opacity: 0; transition: opacity .4s ease; user-select: none; }
.lightbox__image.is-loaded { opacity: 1; }
.lightbox__figure figcaption { display: flex; justify-content: space-between; padding-top: 15px; color: var(--muted); font-size: 9px; letter-spacing: .16em; text-transform: uppercase; }
.lightbox__count { color: var(--accent); }
.lightbox button { border: 0; color: var(--ink); background: transparent; font: inherit; cursor: pointer; }
.lightbox__close { position: absolute; top: 22px; right: 4vw; z-index: 1; font-size: 30px; font-weight: 200; line-height: 1; }
.lightbox__prev, .lightbox__next { width: 48px; height: 48px; border: 1px solid rgba(230, 230, 227, .22) !important; border-radius: 50%; color: var(--accent); font-size: 20px; transition: border-color .25s ease, color .25s ease; }
.lightbox__prev:hover, .lightbox__next:hover { border-color: var(--ink); color: var(--ink); }
.lightbox button:focus-visible { outline: 1px solid var(--accent); outline-offset: 4px; }

@media (max-width: 900px) {
  .hero__image { width: 100%; opacity: .7; background-position: center top; }
  .hero__text { top: auto; bottom: 9vh; transform: none; }
  .hero__seal { top: 12vh; right: 22px; }
  .about__body, .contacts__body { grid-template-columns: minmax(0, 1fr); gap: 6vh; }
  .about__portrait { width: 100%; max-width: 460px; }
}

@media (max-width: 700px) {
  .topbar { padding: 22px; }
  .topbar__link { font-size: 9px; padding: 8px 10px; }
  .hero__text { right: 22px; bottom: 6vh; left: 22px; }
  .hero h1 { font-size: clamp(44px, 14vw, 64px); }
  .hero__lead { max-width: 280px; font-size: 13px; line-height: 1.6; }
  .hero__footer { left: 22px; right: 22px; }
  .hero__footer span:nth-child(3) { display: none; }
  .section-head { grid-template-columns: 1fr; gap: 12px; margin-bottom: 5vh; }
  .section-head .section-rule { display: none; }
  .gallery, .about, .contacts { padding-left: 14px; padding-right: 14px; }
  .gallery .section-title { margin-left: 8px; }
  .gallery__grid { grid-template-columns: 1fr; margin: 0 -14px; }
  .gallery__item { padding: .4cm; aspect-ratio: 4 / 5; }
  .gallery { padding-bottom: 1cm; }
  .about { padding-top: 1cm; }
  .about .section-head { grid-template-columns: auto 1fr; gap: 18px; }
  .about .section-head .section-rule { display: block; }
  html.js .about__body .about__portrait[data-reveal], html.js .about__body .about__portrait[data-reveal].is-revealed { opacity: 1; transform: none; transition: none; }
  .about__subtitle { margin: 12vh 0 24px; padding-top: 18px; border-top: 1px solid var(--line); }
  .about__steps li, .about__facts li { padding: 20px 0; }
  .about__steps span { font-size: 12px; }
  .about__facts strong { margin-bottom: 6px; }
  .about__cta { margin-top: 10vh; }
  .site-footer { padding: 44px 22px 26px; font-size: 8px; }
  .site-footer__top { padding-bottom: 34px; }
  .site-footer .wordmark { font-size: 26px; }
  .site-footer__links { gap: 18px 24px; }
  .site-footer__bottom { flex-direction: row; justify-content: space-between; align-items: center; gap: 12px; }
  .topbar__nav { display: none; }
  .hero .eyebrow, .hero__seal, .hero__footer, .section-count, .gallery__item figcaption { display: none; }
  .hero__lead { margin-top: 18px; }
  .gallery__item figcaption { right: .4cm; bottom: .2cm; left: .4cm; font-size: 8px; }
  .gallery .section-head { display: none; }
  .contacts__cta { font-size: 30px; }
  .about__steps li { font-size: 13px; }
  .about__text .section-title { font-size: clamp(40px, 14vw, 72px); }
  .contacts__body .section-title { font-size: clamp(38px, 10.5vw, 68px); }
  .contacts__address { font-size: 14px; }
  .lightbox { grid-template-columns: 42px minmax(0, 1fr) 42px; padding: 62px 12px 30px; }
  .lightbox__figure { width: 100%; height: 78vh; }
  .lightbox__prev, .lightbox__next { width: 40px; height: 40px; font-size: 16px; }
  .lightbox__close { top: 20px; right: 20px; }
}

@media (hover: none) {
  .gallery__item:hover img { filter: saturate(.9) contrast(1.04); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  html.js [data-reveal], html.js .split .line > span { opacity: 1; transform: none; transition: none; }
  .loader { display: none; }
  .gallery__item img, .lightbox__image { transition: none; }
  .hero__image { transform: none !important; transition: none !important; }
}
