/* ==========================================================================
   JapanTrade.cz — styles
   Structure: tokens → base → utilities → header → hero → projects → about
              → how → contact → footer → motion → responsive
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Tokens
   -------------------------------------------------------------------------- */
:root {
  --bg: #f6f5f2;
  --bg-2: #eeece7;
  --bg-dark: #0b0b0b;
  --ink: #111111;
  --ink-2: #3d3d3d;
  --ink-3: #6b6b6b;
  --muted: #8f8f8f;
  --line: rgba(17, 17, 17, 0.12);
  --line-strong: rgba(17, 17, 17, 0.25);
  --line-light: rgba(255, 255, 255, 0.16);
  --red: #c1121f;
  --red-dark: #9e0f1a;
  --white: #ffffff;

  --font-display: "Inter Tight", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-jp: "Noto Sans JP", "Hiragino Sans", "Yu Gothic", "Meiryo", sans-serif;

  --container: 1360px;
  --gutter: clamp(20px, 4vw, 56px);
  --header-h: 76px;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --t-fast: 220ms;
  --t-med: 480ms;
  --t-slow: 900ms;
}

/* --------------------------------------------------------------------------
   2. Base
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

body.nav-open { overflow: hidden; }

img, svg { display: block; max-width: 100%; }

a { color: inherit; text-decoration: none; }

ul, ol { margin: 0; padding: 0; list-style: none; }

h1, h2, h3, p { margin: 0; }

button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

address { font-style: normal; }

:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 4px;
}

::selection { background: var(--red); color: var(--white); }

/* Subtle film grain over everything, very low opacity. */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 9998;
  pointer-events: none;
  opacity: 0.045;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .6 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  mix-blend-mode: multiply;
}

/* --------------------------------------------------------------------------
   3. Utilities & shared components
   -------------------------------------------------------------------------- */
.container {
  width: min(100% - 2 * var(--gutter), var(--container));
  margin-inline: auto;
}

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

.skip-link {
  position: absolute; top: 8px; left: 8px;
  z-index: 10000;
  padding: 10px 16px;
  background: var(--ink); color: var(--white);
  font-size: 0.875rem; font-weight: 600;
  transform: translateY(-200%);
  transition: transform var(--t-fast);
}
.skip-link:focus { transform: none; }

.jp { font-family: var(--font-jp); font-weight: 500; }

/* Eyebrow: red dash + small caps label */
.eyebrow {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  line-height: 1.5;
  color: var(--ink-2);
}
.eyebrow__line {
  flex: none;
  width: 22px; height: 2px;
  margin-top: 0.45em;
  background: var(--red);
}
.eyebrow--center { justify-content: center; align-items: center; }
.eyebrow--light { color: rgba(255, 255, 255, 0.7); }
.eyebrow--muted { color: var(--muted); }

/* Headings */
.h2 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 1.2rem + 2.6vw, 3.25rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
  text-transform: uppercase;
  margin-top: 16px;
}

/* Arrow links */
.arrow { flex: none; transition: transform var(--t-fast) var(--ease-out); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--red);
}
.link-arrow--small {
  font-size: 0.6875rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.link-arrow:hover .arrow,
.link-arrow:focus-visible .arrow { transform: translateX(5px); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-height: 52px;
  padding: 0 26px;
  font-weight: 600;
  font-size: 0.9375rem;
  line-height: 1;
  border: 1px solid transparent;
  transition: background var(--t-fast), color var(--t-fast), border-color var(--t-fast), transform var(--t-fast) var(--ease-out);
}
.btn--primary {
  background: var(--red);
  color: var(--white);
  border-color: var(--red);
}
.btn--primary:hover { background: var(--red-dark); border-color: var(--red-dark); }
.btn--primary:hover .arrow { transform: translateX(5px); }
.btn--primary:active { transform: translateY(1px); }

.btn--outline {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn--outline:hover { border-color: var(--ink); }

.link-btn { padding: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.link-btn:hover { color: var(--red); }

.btn--text {
  padding: 0 2px;
  min-height: auto;
  position: relative;
  color: var(--ink);
}
.btn--text::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -6px;
  height: 1px;
  background: var(--ink);
  transform-origin: right;
  transition: transform var(--t-med) var(--ease-out);
}
.btn--text:hover::after { transform: scaleX(0.35); transform-origin: left; }

/* Section header with split layout */
.section-head { padding-block: clamp(40px, 4.5vw, 64px) clamp(22px, 2.6vw, 36px); }
.section-head--split {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 48px;
  align-items: end;
}
.section-head__aside {
  display: grid;
  gap: 28px;
  justify-items: start;
  padding-bottom: 6px;
}
.section-head__text {
  max-width: 34ch;
  color: var(--ink-2);
  font-size: 0.9375rem;
}

/* --------------------------------------------------------------------------
   4. Header / nav
   -------------------------------------------------------------------------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 1000;
  height: var(--header-h);
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background var(--t-med), border-color var(--t-med), backdrop-filter var(--t-med), transform var(--t-med) var(--ease-out);
}
.site-header.is-scrolled {
  background: rgba(246, 245, 242, 0.82);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  backdrop-filter: saturate(160%) blur(14px);
  border-bottom-color: var(--line);
}
.site-header.is-hidden { transform: translateY(-100%); }
.site-header.is-open { background: var(--bg); border-bottom-color: var(--line); }
.site-header.is-open.is-hidden { transform: none; }

.site-header__inner {
  height: 100%;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
  line-height: 1;
}
.brand__light { font-weight: 700; color: var(--ink-3); }
.brand__tld {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.5rem;
  letter-spacing: 0.1em;
  color: var(--muted);
  transform: translateY(-0.6em);
}

.nav__list { display: flex; gap: clamp(28px, 4vw, 56px); }
.nav__link {
  position: relative;
  font-size: 0.9375rem;
  font-weight: 500;
  padding-block: 6px;
}
.nav__link::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform var(--t-med) var(--ease-out);
}
.nav__link:hover::after,
.nav__link:focus-visible::after,
.nav__link.is-active::after { transform: scaleX(1); transform-origin: left; }

.site-header__right {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav__shop {
  padding-left: 28px;
  border-left: 1px solid var(--line-strong);
}

/* Language switcher */
.lang__list { display: flex; align-items: center; }
.lang__link {
  position: relative;
  display: inline-block;
  padding: 6px 4px;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  color: var(--muted);
  transition: color var(--t-fast);
}
.lang__list li + li::before {
  content: "/";
  margin: 0 6px;
  font-size: 0.625rem;
  color: var(--line-strong);
}
.lang__link:hover { color: var(--ink); }
.lang__link.is-active { color: var(--ink); }
.lang__link.is-active::after {
  content: "";
  position: absolute;
  left: 4px; right: 4px; bottom: 2px;
  height: 1.5px;
  background: var(--red);
}

.lang--mobile { margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line); }
.lang--mobile .lang__link { font-size: 0.875rem; padding: 8px 6px; }

.nav-toggle {
  display: none;
  justify-self: end;
  width: 44px; height: 44px;
  margin-right: -10px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.nav-toggle__line {
  display: block;
  width: 22px; height: 1.5px;
  background: var(--ink);
  transition: transform var(--t-med) var(--ease-out);
}
.site-header.is-open .nav-toggle__line:nth-child(1) { transform: translateY(3.75px) rotate(45deg); }
.site-header.is-open .nav-toggle__line:nth-child(2) { transform: translateY(-3.75px) rotate(-45deg); }

.mobile-menu {
  position: fixed;
  inset: var(--header-h) 0 0 0;
  background: var(--bg);
  padding: 32px var(--gutter) 48px;
  overflow-y: auto;
}
.mobile-menu[hidden] { display: none; }
.mobile-menu__list a {
  display: block;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 9vw, 3rem);
  line-height: 1;
  letter-spacing: -0.03em;
  text-transform: uppercase;
}
.mobile-menu__list .mobile-menu__shop { color: var(--red); }
.mobile-menu__brands {
  margin-top: 32px;
  display: grid;
  gap: 10px;
  font-size: 0.9375rem;
  color: var(--ink-3);
}

/* --------------------------------------------------------------------------
   5. Hero
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  min-height: 0;
  padding-top: calc(var(--header-h) + clamp(12px, 2vw, 24px));
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg);
}

.hero__grid {
  position: absolute; inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line) 1px, transparent 1px);
  background-size: 120px 120px;
  opacity: 0.35;
  mask-image: radial-gradient(ellipse 60% 70% at 50% 40%, #000 20%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 60% 70% at 50% 40%, #000 20%, transparent 100%);
}

.hero__inner {
  position: relative;
  flex: 1;
  padding-bottom: clamp(20px, 3vw, 40px);
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr) auto;
  gap: clamp(24px, 4vw, 64px);
  align-items: center;
}
.hero__side { grid-column: 3; }

.hero__content { position: relative; z-index: 2; }

.hero__title {
  margin-top: clamp(16px, 2vw, 24px);
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.8rem, 0.4rem + 4.3vw, 4.8rem);
  line-height: 1.04;
  letter-spacing: -0.035em;
  text-transform: uppercase;
}
.hero__title .line { display: block; }
.hero__title .dot { color: var(--red); }

.hero__lead {
  margin-top: clamp(18px, 2.2vw, 28px);
  max-width: 44ch;
  font-size: clamp(1rem, 0.9rem + 0.45vw, 1.2rem);
  line-height: 1.55;
  color: var(--ink-2);
}

.hero__actions {
  margin-top: clamp(22px, 2.6vw, 34px);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 32px;
}

/* Visual: photograph bleeding in from the right, fading into the page */
.hero__visual {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: 70%;
  z-index: 0;
  overflow: hidden;
  transform: translateY(var(--parallax-y, 0));
  will-change: transform;
}
.hero__visual picture,
.hero__visual img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 100% 50%;
}
.hero__visual img { animation: hero-in 1.6s var(--ease-out) both; }
.hero__visual::after {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(to right, var(--bg) 0%, rgba(246, 245, 242, 0.85) 14%, rgba(246, 245, 242, 0) 42%),
    linear-gradient(to top, var(--bg) 0%, rgba(246, 245, 242, 0) 30%),
    linear-gradient(to bottom, var(--bg) 0%, rgba(246, 245, 242, 0.6) 12%, rgba(246, 245, 242, 0) 38%);
}

/* Right side vertical column */
.hero__side {
  position: relative;
  align-self: center;
  padding: 12px 0 12px 22px;
  border-left: 1px solid var(--line-strong);
  display: flex;
  flex-direction: column;
  gap: 22px;
  font-size: 0.6875rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-2);
  line-height: 1.7;
}
.hero__side-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--red);
}
.hero__side-list { display: grid; gap: 2px; }
.hero__side-jp {
  margin-top: 12px;
  font-size: 1.5rem;
  letter-spacing: 0.08em;
  text-transform: none;
  color: var(--ink);
}
.hero__side-note { color: var(--muted); }

.hero__footer {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding-block: 0 16px;
  font-size: 0.625rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}
.hero__scroll { display: inline-flex; align-items: center; gap: 16px; }
.hero__scroll-line {
  width: 1px; height: 28px;
  background: var(--ink);
  transform-origin: top;
  animation: scroll-hint 2.2s var(--ease-in-out) infinite;
}
.hero__tagline {
  font-family: "Segoe Script", "Brush Script MT", "Snell Roundhand", cursive;
  font-size: 1.05rem;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink-3);
  transform: rotate(-6deg) translateY(-4px);
}

/* --------------------------------------------------------------------------
   6. Projects
   -------------------------------------------------------------------------- */
.projects { background: var(--bg); }

.projects__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  padding: 0 6px 6px;
  /* on wide monitors keep the tiles together in the middle instead of spreading out */
  width: min(100%, 1500px);
  margin-inline: auto;
}

.project { position: relative; }

.project__card {
  position: relative;
  isolation: isolate;
  min-height: clamp(340px, 30vw, 440px);
  aspect-ratio: 1 / 0.92;
  max-height: 480px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg-dark);
  color: var(--white);
}

.project__media {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
}
.project__media picture { width: 100%; height: 100%; }
.project__media img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
  transform: scale(1.001);
  transition: transform 1.1s var(--ease-out);
}
.project--kanjo .project__media img { object-position: 74% 50%; }
.project--mono  .project__media img { object-position: 70% 50%; }
.project--import .project__media img { object-position: 50% 50%; }
.project__media::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(0, 0, 0, 0.62) 0%, rgba(0, 0, 0, 0.25) 42%, rgba(0, 0, 0, 0.05) 60%, rgba(0, 0, 0, 0.6) 100%);
  transition: opacity var(--t-slow);
}
.project__card:hover .project__media img,
.project:focus-within .project__media img { transform: scale(1.05); }

.project__body {
  position: relative;
  padding: clamp(20px, 2vw, 28px);
}
.project__num {
  display: block;
  font-size: 0.6875rem;
  letter-spacing: 0.18em;
  color: rgba(255, 255, 255, 0.65);
}
.project__title {
  margin-top: 14px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.75rem, 1.2rem + 1.4vw, 2.5rem);
  line-height: 1;
  letter-spacing: -0.03em;
  text-transform: uppercase;
}
.project__title-b { font-weight: 700; color: rgba(255, 255, 255, 0.55); }
.project__title-accent { color: var(--red); }
.project__reg {
  font-size: 0.4em;
  vertical-align: top;
  color: var(--red);
  margin-left: 2px;
}
.project__desc {
  margin-top: 12px;
  max-width: 30ch;
  font-size: 0.9375rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.82);
}
.project__link {
  position: relative;
  z-index: 2;
  margin-top: 18px;
  color: var(--white);
  padding-bottom: 6px;
}
.project__link::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: var(--red);
  transition: width var(--t-med) var(--ease-out);
}
.project__card:hover .project__link::after { width: 32px; }

.project__tags {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 0 24px;
  padding: 14px clamp(20px, 2vw, 28px);
  border-top: 1px solid var(--line-light);
  font-size: 0.625rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(4px);
}
.project__tags li + li::before {
  content: "";
  display: inline-block;
  width: 1px; height: 8px;
  margin-right: 24px;
  background: var(--line-light);
  vertical-align: middle;
}

/* Whole card is clickable, while the visible link stays the accessible one. */
.project__overlay-link {
  position: absolute; inset: 0;
  z-index: 1;
}

/* --------------------------------------------------------------------------
   7. About + trust
   -------------------------------------------------------------------------- */
.about { padding-block: clamp(48px, 5.5vw, 80px) clamp(40px, 4.5vw, 64px); }

.about__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr) minmax(280px, 0.85fr);
  gap: clamp(32px, 4vw, 64px);
  align-items: start;
}
.about__text {
  display: grid;
  gap: 20px;
  padding-top: 8px;
  color: var(--ink-2);
  font-size: 0.9375rem;
  max-width: 44ch;
}

.trust {
  position: relative;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  background:
    radial-gradient(circle at 1px 1px, rgba(17, 17, 17, 0.14) 1px, transparent 1.5px) 0 0 / 16px 16px,
    var(--bg-2);
  border: 1px solid var(--line);
}
/* The map is a normal in-flow image with padding around it: it can never be cropped
   and never touches the card edge, whatever the viewport. */
.trust__map {
  width: 100%;
  padding: 6px 8px 0;
}
.trust__map img {
  display: block;
  width: 100%;
  max-width: 460px;
  height: auto;
  margin-inline: auto;
  object-fit: contain;
}
.trust__title {
  position: relative;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1rem;
  line-height: 1.35;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.trust__text {
  position: relative;
  margin-top: -6px;
  font-size: 0.8125rem;
  color: var(--ink-3);
  max-width: 34ch;
}

/* --------------------------------------------------------------------------
   8. How we work
   -------------------------------------------------------------------------- */
.how { margin-top: clamp(40px, 4.5vw, 64px); }

.how__steps {
  margin-top: 24px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  border-top: 1px solid var(--line);
}
.how__step {
  position: relative;
  padding: 24px 28px 24px 0;
}
.how__step + .how__step { padding-left: 28px; }
.how__step + .how__step::before {
  content: "";
  position: absolute;
  left: 0; top: 24px; bottom: 24px;
  width: 1px;
  background: var(--line);
}
/* Chevron between steps */
.how__step + .how__step::after {
  content: "";
  position: absolute;
  left: -6px; top: 30px;
  width: 10px; height: 10px;
  border-top: 1px solid var(--ink-3);
  border-right: 1px solid var(--ink-3);
  transform: rotate(45deg);
  background: var(--bg);
}
.how__num {
  display: block;
  font-size: 0.6875rem;
  letter-spacing: 0.18em;
  color: var(--muted);
}
.how__icon {
  width: 32px; height: 32px;
  margin-top: 16px;
  color: var(--ink);
}
.how__title {
  margin-top: 14px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.125rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.how__text {
  margin-top: 10px;
  font-size: 0.875rem;
  color: var(--ink-2);
  max-width: 28ch;
}

/* --------------------------------------------------------------------------
   9. Contact
   -------------------------------------------------------------------------- */
.contact {
  position: relative;
  color: var(--white);
  background: var(--bg-dark);
  overflow: hidden;
  padding-block: clamp(44px, 5vw, 72px);
}
.contact__bg { position: absolute; inset: 0; }
.contact__bg picture,
.contact__bg img { width: 100%; height: 100%; object-fit: cover; object-position: 30% 50%; }
.contact__bg::after {
  content: "";
  position: absolute; inset: 0;
  background:
    linear-gradient(to right, rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.55) 45%, rgba(0, 0, 0, 0.45)),
    radial-gradient(ellipse 60% 80% at 50% 50%, rgba(0, 0, 0, 0.35), rgba(0, 0, 0, 0.7));
}

.contact__inner {
  position: relative;
  text-align: center;
  display: grid;
  justify-items: center;
}
.contact__title {
  margin: 18px 0 28px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.2rem, 1.2rem + 3.2vw, 3.8rem);
  line-height: 0.98;
  letter-spacing: -0.035em;
  text-transform: uppercase;
}
.contact__title .line { display: block; }

.contact__details {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.6);
}
.contact__company { font-weight: 600; color: var(--white); }
.contact__details a { border-bottom: 1px solid rgba(255, 255, 255, 0.3); transition: border-color var(--t-fast); }
.contact__details a:hover { border-color: var(--white); }

.company {
  margin: 14px 0 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 26px;
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.55);
}
.company__row { display: flex; gap: 8px; align-items: baseline; }
.company dt {
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.38);
}
.company dd { margin: 0; color: rgba(255, 255, 255, 0.72); }

.contact__side {
  position: absolute;
  right: var(--gutter);
  top: 50%;
  transform: translateY(-50%);
  text-align: right;
  font-size: 0.625rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.8;
}
.contact__jp {
  writing-mode: vertical-rl;
  margin-left: auto;
  margin-bottom: 40px;
  font-size: 1.35rem;
  letter-spacing: 0.35em;
  text-transform: none;
  color: rgba(255, 255, 255, 0.85);
}

/* --------------------------------------------------------------------------
   9b. Subpages (inquiry, privacy, legal)
   -------------------------------------------------------------------------- */
.is-subpage .site-header {
  background: rgba(246, 245, 242, 0.92);
  border-bottom-color: var(--line);
}
.page__hero {
  padding: calc(var(--header-h) + clamp(32px, 5vw, 64px)) 0 clamp(28px, 4vw, 48px);
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(to right, var(--line) 1px, transparent 1px) 0 0 / 120px 120px,
    linear-gradient(to bottom, var(--line) 1px, transparent 1px) 0 0 / 120px 120px,
    var(--bg);
  background-blend-mode: normal;
}
.page__title { max-width: 16ch; }
.page__lead {
  margin-top: 18px;
  max-width: 60ch;
  font-size: clamp(1rem, 0.9rem + 0.35vw, 1.125rem);
  color: var(--ink-2);
}
.page__body { padding: clamp(40px, 5vw, 72px) 0 clamp(56px, 7vw, 96px); }

.prose { max-width: 72ch; font-size: 0.9375rem; line-height: 1.7; color: var(--ink-2); }
.prose h2 {
  margin: 36px 0 10px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.125rem;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  color: var(--ink);
}
.prose h2:first-of-type { margin-top: 0; }
.prose p + p { margin-top: 12px; }
.prose a { color: var(--red); border-bottom: 1px solid rgba(193, 18, 31, 0.35); }
.prose a:hover { border-color: var(--red); }
.prose strong { color: var(--ink); }
.prose .btn { color: var(--white); border-bottom: 0; }
.page__lead:empty { display: none; }
.prose__meta { margin-bottom: 28px; font-size: 0.6875rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); }
.prose .fb { margin: 0 0 28px; }

.inquiry {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(260px, 0.7fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}
.form__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px 28px;
}
.field { display: grid; gap: 8px; }
.field--full { grid-column: 1 / -1; }
.field__label {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.field__req { color: var(--red); }
.field__input {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 0;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 0.9375rem;
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
  -webkit-appearance: none;
  appearance: none;
}
.field__input:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 3px rgba(17, 17, 17, 0.08); }
.field__input:user-invalid,
.form.was-validated .field__input:invalid { border-color: var(--red); }
.field__textarea { resize: vertical; min-height: 160px; line-height: 1.55; }
.field__select {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'><path d='M1 1l5 5 5-5' fill='none' stroke='%23111' stroke-width='1.5'/></svg>");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 40px;
}
.field--check {
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 12px;
  font-size: 0.8125rem;
  color: var(--ink-2);
}
.field--check a { color: var(--ink); border-bottom: 1px solid var(--line-strong); }
.field__check { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--red); }
.field--hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form { position: relative; }
.form__actions { margin-top: 28px; display: flex; flex-wrap: wrap; align-items: center; gap: 20px; }
.form__note { font-size: 0.75rem; color: var(--muted); }
.form__status { margin-top: 18px; font-size: 0.875rem; font-weight: 500; min-height: 1.4em; }
.form__status.is-success { color: #157347; }
.form__status.is-error { color: var(--red); }
.form.is-sending .btn { opacity: 0.6; pointer-events: none; }

.inquiry__aside { padding: 28px; background: var(--bg-2); border: 1px solid var(--line); }
.inquiry__aside-text { margin-top: 18px; font-size: 0.9375rem; color: var(--ink-2); }
.inquiry__contacts { margin-top: 18px; display: grid; gap: 6px; font-weight: 600; }
.inquiry__contacts a { border-bottom: 1px solid var(--line-strong); }
.inquiry__contacts a:hover { color: var(--red); border-color: var(--red); }
.inquiry__company { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); font-size: 0.8125rem; line-height: 1.7; color: var(--ink-3); }
.inquiry__aside .fb { margin-top: 20px; }
.field--captcha { min-height: 0; }
.field--captcha:empty { display: none; }
.notfound__actions { margin-top: 28px; }

/* --------------------------------------------------------------------------
   10. Footer
   -------------------------------------------------------------------------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding-block: 40px 32px;
  font-size: 0.875rem;
}
.site-footer__grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr auto;
  gap: 40px;
  align-items: start;
}
.site-footer__copy { margin-top: 20px; font-size: 0.75rem; color: var(--ink-3); }
.site-footer__credit { margin-top: 8px; font-size: 0.75rem; color: var(--muted); }
.site-footer__credit a { color: var(--ink-2); border-bottom: 1px solid var(--line-strong); transition: color var(--t-fast), border-color var(--t-fast); }
.site-footer__credit a:hover { color: var(--red); border-color: var(--red); }
.site-footer__heart { color: var(--red); }
.site-footer__heading {
  font-size: 0.8125rem;
  font-weight: 600;
  margin-bottom: 14px;
}
.site-footer__col ul { display: grid; gap: 8px; color: var(--ink-2); }
.site-footer__col a { transition: color var(--t-fast); }
.site-footer__col a:hover { color: var(--red); }
.site-footer__social { display: grid; gap: 28px; justify-items: end; text-align: right; align-self: start; }
.site-footer__social .eyebrow { flex-direction: row-reverse; text-align: right; }
.social { display: flex; gap: 22px; }
.social a { display: block; color: var(--ink); transition: color var(--t-fast), transform var(--t-fast) var(--ease-out); }
.social a:hover { color: var(--red); transform: translateY(-2px); }

/* --------------------------------------------------------------------------
   11. Cursor (desktop, fine pointer only)
   -------------------------------------------------------------------------- */
.cursor { display: none; }
@media (hover: hover) and (pointer: fine) {
  .cursor {
    display: block;
    position: fixed;
    top: 0; left: 0;
    z-index: 9999;
    pointer-events: none;
    mix-blend-mode: difference;
    opacity: 0;
    transition: opacity var(--t-med);
  }
  .cursor.is-visible { opacity: 1; }
  .cursor__dot {
    display: block;
    width: 10px; height: 10px;
    border-radius: 50%;
    background: #fff;
    transform: translate(-50%, -50%) scale(1);
    transition: transform var(--t-med) var(--ease-out), background var(--t-fast);
  }
  .cursor.is-link .cursor__dot { transform: translate(-50%, -50%) scale(4); background: #fff; }
}

/* --------------------------------------------------------------------------
   12. Motion: reveal + keyframes
   -------------------------------------------------------------------------- */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity var(--t-slow) var(--ease-out),
    transform var(--t-slow) var(--ease-out);
  transition-delay: calc(var(--i, 0) * 90ms);
}
.js [data-reveal].is-in { opacity: 1; transform: none; }

@keyframes hero-in {
  from { transform: scale(1.06); opacity: 0; }
  to   { transform: none; opacity: 1; }
}
@keyframes scroll-hint {
  0%   { transform: scaleY(0); transform-origin: top; }
  50%  { transform: scaleY(1); transform-origin: top; }
  51%  { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
  .hero__visual { transform: none !important; }
  .hero__visual img { animation: none; }
  .cursor { display: none !important; }
}

/* --------------------------------------------------------------------------
   13. Japanese locale typography
   Headlines switch to Noto Sans JP; Latin brand names keep Inter Tight.
   -------------------------------------------------------------------------- */
html[lang="ja"] {
  --font-body: "Noto Sans JP", "Inter", system-ui, sans-serif;
  --font-display: "Noto Sans JP", "Inter Tight", system-ui, sans-serif;
}
html[lang="ja"] .brand,
html[lang="ja"] .project__title { font-family: "Inter Tight", "Inter", system-ui, sans-serif; }

html[lang="ja"] .hero__title,
html[lang="ja"] .h2,
html[lang="ja"] .contact__title,
html[lang="ja"] .mobile-menu__list a {
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.18;
}
html[lang="ja"] .hero__title { font-size: clamp(2.4rem, 0.4rem + 3.9vw, 4.4rem); }
html[lang="ja"] .h2 { font-size: clamp(1.75rem, 1rem + 2.1vw, 2.75rem); }
html[lang="ja"] .contact__title { font-size: clamp(2rem, 1rem + 3.2vw, 3.6rem); }
html[lang="ja"] .trust__title,
html[lang="ja"] .how__title { font-weight: 700; letter-spacing: 0.04em; line-height: 1.5; }
html[lang="ja"] .eyebrow,
html[lang="ja"] .hero__side,
html[lang="ja"] .hero__footer,
html[lang="ja"] .project__tags,
html[lang="ja"] .contact__side,
html[lang="ja"] .link-arrow--small { letter-spacing: 0.12em; }
html[lang="ja"] .hero__tagline { font-family: var(--font-jp); font-size: 0.8rem; letter-spacing: 0.1em; transform: none; }
html[lang="ja"] .hero__lead,
html[lang="ja"] .about__text,
html[lang="ja"] .section-head__text { line-height: 1.85; }
html[lang="ja"] .contact__title { text-transform: none; }

/* --------------------------------------------------------------------------
   13b. Cookie consent
   -------------------------------------------------------------------------- */
.cc {
  position: fixed;
  z-index: 9000;
  right: 20px; bottom: 20px;
  width: min(420px, calc(100vw - 40px));
}
.cc[hidden] { display: none; }
.cc__panel {
  padding: 24px 24px 22px;
  background: rgba(246, 245, 242, 0.96);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid var(--line-strong);
  box-shadow: 0 24px 60px -24px rgba(0, 0, 0, 0.35);
  animation: cc-in 0.5s var(--ease-out) both;
}
@keyframes cc-in {
  from { transform: translateY(16px); opacity: 0; }
  to   { transform: none; opacity: 1; }
}
.cc__eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 0.625rem; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-3);
}
.cc__eyebrow .eyebrow__line { margin-top: 0; width: 16px; }
.cc__title {
  margin-top: 10px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.125rem;
  line-height: 1.2;
  letter-spacing: -0.01em;
}
.cc__text { margin-top: 10px; font-size: 0.8125rem; line-height: 1.55; color: var(--ink-2); }
.cc__text a { color: var(--ink); border-bottom: 1px solid var(--line-strong); }
.cc__text a:hover { color: var(--red); border-color: var(--red); }

.cc__prefs { margin-top: 16px; border-top: 1px solid var(--line); }
.cc__prefs[hidden] { display: none; }
.cc__row {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.cc__row--locked { cursor: default; }
.cc__row-text { display: grid; gap: 2px; font-size: 0.75rem; line-height: 1.45; color: var(--ink-3); }
.cc__row-text strong { font-size: 0.8125rem; color: var(--ink); }
.cc__switch { position: relative; flex: none; width: 40px; height: 22px; }
.cc__switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: inherit; }
.cc__knob {
  position: absolute; inset: 0;
  background: #cfcdc7;
  border-radius: 11px;
  transition: background var(--t-fast);
}
.cc__knob::after {
  content: ""; position: absolute; top: 3px; left: 3px;
  width: 16px; height: 16px; border-radius: 50%; background: #fff;
  transition: transform var(--t-fast) var(--ease-out);
}
.cc__switch input:checked + .cc__knob { background: var(--red); }
.cc__switch input:checked + .cc__knob::after { transform: translateX(18px); }
.cc__switch input:disabled + .cc__knob { background: var(--ink-3); opacity: 0.6; }
.cc__switch input:focus-visible + .cc__knob { outline: 2px solid var(--red); outline-offset: 3px; }

.cc__actions { margin-top: 18px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.cc__btn { min-height: 42px; padding: 0 18px; font-size: 0.8125rem; }
.cc__btn[hidden] { display: none; }
.cc__link {
  margin-left: auto;
  padding: 6px 0;
  font-size: 0.75rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-3);
  border-bottom: 1px solid transparent;
}
.cc__link:hover { color: var(--ink); border-color: var(--ink); }
.cc.is-prefs .cc__link { display: none; }

html.og-shot .cc { display: none !important; }

@media (max-width: 520px) {
  .cc { right: 10px; bottom: 10px; width: calc(100vw - 20px); }
  .cc__panel { padding: 20px 18px 18px; }
  .cc__actions .cc__btn { flex: 1 1 100%; }
  .cc__link { margin-left: 0; }
}
@media (prefers-reduced-motion: reduce) { .cc__panel { animation: none; } }

/* --------------------------------------------------------------------------
   14. Review / feedback notes (removed by `python tools/build.py --release`)
   -------------------------------------------------------------------------- */
.fb {
  position: relative;
  z-index: 6;
  margin: 18px 0 0;
  padding: 12px 14px 12px 42px;
  border: 2px dashed #e11d2e;
  background: rgba(225, 29, 46, 0.07);
  color: #9b0f1c;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: 0;
  text-transform: none;
  text-align: left;
  pointer-events: auto;
}
.fb::before {
  content: "?";
  position: absolute;
  left: 12px; top: 11px;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: #e11d2e;
  color: #fff;
  font-weight: 800;
  font-size: 0.75rem;
  line-height: 20px;
  text-align: center;
}
.fb strong { display: block; margin-bottom: 4px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; font-size: 0.6875rem; }
.fb code { font-family: ui-monospace, Consolas, monospace; font-size: 0.75rem; background: rgba(0, 0, 0, 0.06); padding: 0 4px; }
.fb--dark { background: rgba(225, 29, 46, 0.16); color: #ffb4bb; border-color: #ff4d5e; max-width: 720px; }
.fb--dark code { background: rgba(255, 255, 255, 0.12); }
.fb--card {
  position: absolute;
  left: 12px; right: 12px; bottom: 56px;
  margin: 0;
  background: rgba(20, 0, 3, 0.86);
  color: #ffb4bb;
  border-color: #ff4d5e;
}
.fb--card code { background: rgba(255, 255, 255, 0.12); }
.fb-toggle {
  position: fixed;
  left: 16px; bottom: 16px;
  z-index: 10001;
  padding: 10px 14px;
  border: 2px solid #e11d2e;
  background: #e11d2e;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  box-shadow: 0 8px 24px -8px rgba(0, 0, 0, 0.5);
}
.fb-toggle[aria-pressed="false"] { background: #fff; color: #e11d2e; }
html.fb-off .fb { display: none; }

/* ?og=1 — clean state for the Open Graph screenshot (tools/screenshot-og.py) */
html.og-shot .fb, html.og-shot .fb-toggle, html.og-shot .cursor, html.og-shot .hero__scroll { display: none !important; }
html.og-shot [data-reveal] { opacity: 1 !important; transform: none !important; transition: none !important; }
html.og-shot .hero__visual img { animation: none !important; }
html.og-shot .site-header { position: absolute; }
@media (max-width: 699px) {
  .fb--card { position: relative; inset: auto; margin: 12px; }
  .project__card:has(.fb--card) { aspect-ratio: auto !important; }
}

/* --------------------------------------------------------------------------
   15. Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1180px) {
  .hero__inner { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); }
  .hero__side { display: none; }
  .hero__visual { width: 64%; }
  .about__grid { grid-template-columns: 1fr 1fr; }
  .trust { grid-column: 1 / -1; max-width: 520px; }
  .site-footer__grid { grid-template-columns: 1.4fr 1fr 1fr 1fr; }
  .site-footer__social { grid-column: 1 / -1; justify-items: start; text-align: left; }
  .site-footer__social .eyebrow { flex-direction: row; text-align: left; }
}

@media (max-width: 1024px) {
  .nav, .site-header__right { display: none; }
  .nav-toggle { display: inline-flex; }
  .site-header__inner { grid-template-columns: 1fr auto; }

  .projects__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .project:nth-child(odd):last-child { grid-column: 1 / -1; }
  .project:nth-child(odd):last-child .project__card { aspect-ratio: 2 / 1; min-height: 320px; }

  .how__steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .how__step { padding: 28px 24px 28px 0; }
  .how__step + .how__step { padding-left: 24px; }
  .how__step:nth-child(odd) { padding-left: 0; }
  .how__step:nth-child(odd)::before,
  .how__step:nth-child(odd)::after { display: none; }
  .how__step:nth-child(n + 3) { border-top: 1px solid var(--line); }

  .contact__side { display: none; }
}

@media (max-width: 820px) {
  :root { --header-h: 64px; }

  .hero {
    min-height: auto;
    padding-top: calc(var(--header-h) + 32px);
  }
  .hero__inner {
    grid-template-columns: 1fr;
    gap: 0;
  }
  .hero__visual {
    position: relative;
    inset: auto;
    width: 100%;
    margin: 0 0 -10%;
    aspect-ratio: 16 / 10;
    transform: none !important;
  }
  .hero__visual img { object-position: 64% 40%; }
  .hero__visual::after {
    background:
      linear-gradient(to top, var(--bg) 0%, rgba(246, 245, 242, 0) 45%),
      linear-gradient(to bottom, rgba(246, 245, 242, 0.6) 0%, rgba(246, 245, 242, 0) 25%);
  }
  .hero__title { font-size: clamp(2.5rem, 11vw, 4.5rem); }
  .hero__footer { padding-top: 40px; }
  .hero__tagline { display: none; }

  .section-head--split { grid-template-columns: 1fr; gap: 28px; }

  .about__grid { grid-template-columns: 1fr; }
  .trust { max-width: none; }
  .inquiry { grid-template-columns: 1fr; }

  .site-footer__grid { grid-template-columns: 1fr 1fr; }
  .site-footer__brand { grid-column: 1 / -1; }
}

@media (max-width: 699px) {
  .projects__grid { grid-template-columns: 1fr; gap: 4px; padding: 0 4px 4px; }
  .project:nth-child(odd):last-child { grid-column: auto; }
  .project__card,
  .project:nth-child(odd):last-child .project__card {
    aspect-ratio: 1 / 1;
    min-height: 360px;
    max-height: none;
  }
}

@media (max-width: 520px) {
  .form__grid { grid-template-columns: 1fr; }
  .how__steps { grid-template-columns: 1fr; }
  .how__step { padding: 24px 0 !important; border-top: 1px solid var(--line); }
  .how__step:first-child { border-top: 0; }
  .how__step::before, .how__step::after { display: none !important; }

  .hero__actions { gap: 22px; }
  .btn--primary { width: 100%; }

  .contact__details { flex-direction: column; gap: 6px; }
  .contact__sep { display: none; }
  .company { flex-direction: column; align-items: center; gap: 8px; }
  .company__row { flex-direction: column; align-items: center; gap: 2px; text-align: center; }
}
