/* =========================================================
   JUNKBRANDING — Creative Consulting LP (Demo 02)
   Layers: reset → tokens → base → layout → components → sections → utilities
   ========================================================= */
@layer reset, tokens, base, layout, components, sections, utilities;

@layer reset {
  *, *::before, *::after { box-sizing: border-box; }
  * { margin: 0; }
  html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
  img, svg, video { display: block; max-width: 100%; height: auto; }
  input, button, textarea, select { font: inherit; color: inherit; }
  button { background: none; border: 0; padding: 0; cursor: pointer; }
  ul[role="list"], ol[role="list"] { list-style: none; padding: 0; }
  fieldset { border: 0; padding: 0; min-width: 0; }
}

@layer tokens {
  :root {
    /* Color — 4 tones only */
    --ink: #0e0e0c;
    --paper: #efeee9;
    --accent: #ff4f00;
    --mute: #6f6e69;

    --line: color-mix(in oklab, var(--ink) 16%, transparent);
    --bg: var(--paper);
    --fg: var(--ink);
    --fg-mute: var(--mute);

    /* Type */
    --font-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
    --font-body: "Zen Kaku Gothic New", "Hiragino Sans", "Yu Gothic", sans-serif;

    --fs-label: 0.75rem;
    --fs-body: clamp(0.9375rem, 0.9rem + 0.15vw, 1.0625rem);
    --fs-h4: clamp(1.125rem, 1rem + 0.5vw, 1.375rem);
    --fs-h2: clamp(2.25rem, 1.4rem + 4.2vw, 5.25rem);
    --fs-display: min(23vw, 34svh);

    /* Space */
    --margin: clamp(1.25rem, 0.6rem + 3vw, 3.5rem);
    --gutter: clamp(1rem, 0.6rem + 1.4vw, 2rem);
    --section: clamp(6rem, 4rem + 9vw, 12rem);
    --header-h: 4rem;

    --cols: 4;
    --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  }

  @media (min-width: 768px) { :root { --cols: 8; } }
  @media (min-width: 1024px) { :root { --cols: 12; --header-h: 4.5rem; } }
}

@layer base {
  html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 1rem); background: var(--paper); }
  @media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

  body {
    background: var(--bg);
    color: var(--fg);
    font-family: var(--font-body);
    font-size: var(--fs-body);
    line-height: 1.8;
    letter-spacing: 0.02em;
    font-feature-settings: "palt" 1;
    -webkit-font-smoothing: antialiased;
    overflow-x: clip;
  }

  h1, h2, h3, h4 { line-height: 1.2; font-weight: 700; text-wrap: balance; word-break: auto-phrase; }
  p { text-wrap: pretty; word-break: auto-phrase; line-break: strict; }

  a { color: inherit; text-underline-offset: 0.25em; text-decoration-thickness: 1px; }
  a:hover { text-decoration-color: var(--accent); }

  :focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
  ::selection { background: var(--accent); color: var(--ink); }
}

@layer layout {
  .grid {
    display: grid;
    grid-template-columns: repeat(var(--cols), minmax(0, 1fr));
    column-gap: var(--gutter);
    padding-inline: var(--margin);
  }
  .grid > * { grid-column: 1 / -1; }

  .section { padding-block: var(--section); background: var(--bg); color: var(--fg); position: relative; }

  .theme-ink { --bg: var(--ink); --fg: var(--paper); --fg-mute: color-mix(in oklab, var(--paper) 62%, var(--ink)); --line: color-mix(in oklab, var(--paper) 18%, transparent); }
  .theme-accent { --bg: var(--accent); --fg: var(--ink); --fg-mute: color-mix(in oklab, var(--ink) 72%, var(--accent)); --line: color-mix(in oklab, var(--ink) 28%, transparent); }
}

@layer components {
  .label {
    font-family: var(--font-display);
    font-size: var(--fs-label);
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    line-height: 1.4;
  }
  .section-label { color: var(--fg-mute); margin-bottom: 1.5rem; }

  .h2 { font-size: var(--fs-h2); letter-spacing: -0.02em; line-height: 1.12; }
  .h4 { font-size: var(--fs-h4); letter-spacing: 0; line-height: 1.45; }

  /* Buttons */
  .btn {
    --btn-bg: var(--fg);
    --btn-fg: var(--bg);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    min-height: 2.75rem;
    padding: 0.625rem 1.25rem;
    background: var(--btn-bg);
    color: var(--btn-fg);
    font-weight: 700;
    font-size: 0.9375rem;
    text-decoration: none;
    border: 1px solid var(--btn-bg);
    border-radius: 999px;
    transition: background-color .35s var(--ease-out), color .35s var(--ease-out), border-color .35s var(--ease-out);
    white-space: nowrap;
  }
  .btn--accent { --btn-bg: var(--accent); --btn-fg: var(--ink); }
  .btn--ghost { --btn-bg: transparent; --btn-fg: var(--fg); border-color: var(--fg); }
  .btn--lg { min-height: 3.5rem; padding-inline: 1.75rem; font-size: 1rem; }
  .btn--block { width: 100%; }
  .btn__arrow { display: inline-block; transition: transform .45s var(--ease-out); font-family: var(--font-display); }
  @media (hover: hover) {
    .btn:hover { --btn-bg: var(--fg); --btn-fg: var(--bg); border-color: var(--fg); }
    .theme-ink .btn--accent:hover { --btn-bg: var(--paper); --btn-fg: var(--ink); }
    .btn--ghost:hover { --btn-bg: var(--fg); --btn-fg: var(--bg); }
    .btn:hover .btn__arrow { transform: translateX(0.3rem); }
  }

  .skip-link {
    position: fixed; left: 1rem; top: 1rem; z-index: 100;
    padding: .75rem 1rem; background: var(--accent); color: var(--ink); font-weight: 700;
    transform: translateY(-200%);
  }
  .skip-link:focus { transform: none; }

  .demo-bar {
    background: var(--ink); color: var(--paper);
    font-size: 0.75rem; line-height: 1.5; text-align: center;
    padding: 0.5rem var(--margin);
  }

  /* Header */
  .site-header {
    position: sticky; top: 0; z-index: 50;
    height: var(--header-h);
    background: color-mix(in oklab, var(--paper) 88%, transparent);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid transparent;
    transition: transform .5s var(--ease-out), border-color .3s;
  }
  .site-header.is-scrolled { border-bottom-color: var(--line); }
  .site-header.is-hidden { transform: translateY(-100%); }
  .site-header__inner {
    height: 100%;
    display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
    padding-inline: var(--margin);
  }

  .logo { display: inline-flex; align-items: center; gap: 0.625rem; text-decoration: none; }
  .logo__mark { width: 0.875rem; height: 0.875rem; background: var(--accent); }
  .logo__type { font-family: var(--font-display); font-weight: 800; font-variation-settings: "wdth" 88; letter-spacing: -0.01em; font-size: 1.0625rem; }

  .nav { display: none; }
  .nav__list { display: flex; gap: 2rem; list-style: none; padding: 0; }
  .nav__link { font-family: var(--font-display); font-size: .875rem; font-weight: 500; text-decoration: none; position: relative; }
  .nav__link::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: -0.25rem; height: 1px; background: var(--accent);
    transform: scaleX(0); transform-origin: right; transition: transform .45s var(--ease-out);
  }
  .nav__link:hover::after, .nav__link[aria-current="true"]::after { transform: scaleX(1); transform-origin: left; }

  .menu-toggle { display: inline-flex; align-items: center; gap: .75rem; min-height: 2.75rem; padding-inline: .25rem; font-family: var(--font-display); font-weight: 500; font-size: .875rem; }
  .menu-toggle__lines { display: grid; gap: 6px; width: 22px; }
  .menu-toggle__lines span { height: 2px; background: currentColor; transition: transform .4s var(--ease-out); }
  .menu-toggle[aria-expanded="true"] .menu-toggle__lines span:first-child { transform: translateY(4px) rotate(45deg); }
  .menu-toggle[aria-expanded="true"] .menu-toggle__lines span:last-child { transform: translateY(-4px) rotate(-45deg); }

  @media (max-width: 1023.98px) {
    .nav.is-open {
      display: flex; flex-direction: column; justify-content: space-between; gap: 2rem;
      position: fixed; inset: var(--header-h) 0 0 0; height: calc(100dvh - var(--header-h));
      padding: 2rem var(--margin) calc(2rem + env(safe-area-inset-bottom));
      background: var(--ink); color: var(--paper);
    }
    .nav.is-open .nav__list { flex-direction: column; gap: .25rem; }
    .nav.is-open .nav__link { font-size: clamp(2.5rem, 12vw, 4rem); font-weight: 700; font-variation-settings: "wdth" 80; letter-spacing: -0.02em; line-height: 1.15; }
    .nav.is-open .nav__cta { align-self: stretch; min-height: 3.5rem; }
  }
  @media (min-width: 1024px) {
    .nav { display: flex; align-items: center; gap: 2.5rem; }
    .menu-toggle { display: none; }
  }

  /* Form controls */
  .field { display: grid; gap: .5rem; }
  .field label, .field legend { font-weight: 700; font-size: .9375rem; }
  .field__req, .field__opt { font-family: var(--font-display); font-size: .6875rem; font-weight: 600; letter-spacing: .06em; padding: .125rem .5rem; border-radius: 999px; margin-left: .375rem; vertical-align: middle; }
  .field__req { background: var(--accent); color: var(--ink); }
  .field__opt { border: 1px solid var(--line); color: var(--fg-mute); }

  .field input:not([type="radio"], [type="checkbox"]), .field select, .field textarea {
    width: 100%;
    min-height: 3.25rem;
    padding: .75rem 0;
    background: transparent;
    border: 0;
    border-bottom: 1px solid color-mix(in oklab, var(--fg) 40%, transparent);
    border-radius: 0;
    font-size: 1rem;
    transition: border-color .3s;
  }
  .field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(-45deg, transparent 50%, currentColor 50%); background-position: calc(100% - 10px) 55%, calc(100% - 4px) 55%; background-size: 6px 6px; background-repeat: no-repeat; }
  .field select option { color: var(--ink); background: var(--paper); }
  .field textarea { resize: vertical; line-height: 1.7; }
  .field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: none; border-bottom-color: var(--accent); box-shadow: 0 1px 0 0 var(--accent); }
  .field [aria-invalid="true"] { border-bottom-color: var(--accent) !important; }
  .field__error { color: var(--accent); font-size: .875rem; font-weight: 500; min-height: 0; }
  .field__error:empty { display: none; }
  .field__hint { color: var(--fg-mute); font-size: .8125rem; font-family: var(--font-display); }

  .radios { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .5rem; }
  .radio { position: relative; cursor: pointer; }
  .radio input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
  .radio span { display: inline-flex; align-items: center; min-height: 2.75rem; padding: 0 1rem; border: 1px solid color-mix(in oklab, var(--fg) 35%, transparent); border-radius: 999px; font-size: .875rem; transition: background-color .25s, color .25s, border-color .25s; }
  .radio input:checked + span { background: var(--fg); color: var(--bg); border-color: var(--fg); }
  .radio input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

  .check { display: flex; align-items: flex-start; gap: .75rem; cursor: pointer; font-weight: 500; }
  .check input { appearance: none; flex: none; width: 1.375rem; height: 1.375rem; margin-top: .2rem; border: 1px solid var(--fg); display: grid; place-content: center; cursor: pointer; }
  .check input::after { content: ""; width: .75rem; height: .75rem; background: var(--accent); transform: scale(0); transition: transform .25s var(--ease-out); }
  .check input:checked::after { transform: scale(1); }
}

@layer sections {
  /* Hero ------------------------------------------------ */
  .hero {
    min-height: calc(100svh - var(--header-h));
    display: flex; flex-direction: column; justify-content: space-between; gap: clamp(2rem, 4vw, 3rem);
    padding-block: clamp(1.5rem, 3vw, 2.5rem) clamp(2rem, 4vw, 3rem);
    overflow: hidden;
  }
  .hero__meta { row-gap: .25rem; }
  .hero__meta-right { color: var(--fg-mute); }

  .hero__title { display: grid; gap: clamp(1.5rem, 3vw, 2.5rem); padding-inline: var(--margin); font-weight: inherit; }
  .hero__display {
    display: block;
    font-family: var(--font-display);
    font-size: var(--fs-display);
    font-weight: 800;
    font-variation-settings: "wdth" 72;
    line-height: 0.84;
    letter-spacing: -0.045em;
    text-transform: none;
  }
  .hero__line { display: flex; align-items: flex-end; overflow: hidden; padding-bottom: 0.2em; margin-bottom: -0.16em; }
  .hero__line--2 { gap: 0.08em; padding-left: 0.62em; }
  .hero__arrow {
    display: inline-flex; align-items: center; justify-content: center;
    width: 0.92em; height: 0.74em; margin-bottom: 0.03em;
    background: var(--accent); color: var(--ink);
    font-size: 1em; line-height: 1;
    overflow: hidden;
  }
  .hero__arrow > span { font-size: 0.62em; font-weight: 600; font-variation-settings: "wdth" 100; letter-spacing: 0; transform: translateY(-0.04em); }
  .hero__jp {
    display: block;
    font-family: var(--font-body);
    font-size: clamp(1.75rem, 1.2rem + 2.6vw, 3.5rem);
    font-weight: 700;
    letter-spacing: 0.04em;
    line-height: 1.3;
  }
  .char { display: inline-block; will-change: transform; }

  .hero__foot { row-gap: 1.75rem; align-items: end; }
  .hero__lead { max-width: 36em; color: color-mix(in oklab, var(--fg) 82%, var(--bg)); }
  .hero__actions { display: flex; flex-wrap: wrap; gap: .75rem; }
  .hero__scroll { display: none; align-items: center; gap: .75rem; text-decoration: none; color: var(--fg-mute); }
  .hero__scroll-line { width: 3rem; height: 1px; background: currentColor; position: relative; overflow: hidden; }
  .hero__scroll-line::after { content: ""; position: absolute; inset: 0; background: var(--accent); transform: translateX(-100%); animation: scrollcue 2.4s var(--ease-out) infinite; }
  @keyframes scrollcue { 60%, 100% { transform: translateX(100%); } }

  @media (min-width: 768px) {
    .hero__meta > :first-child { grid-column: 1 / span 4; }
    .hero__meta-right { grid-column: 5 / -1; text-align: right; }
    .hero__lead { grid-column: 1 / span 5; }
    .hero__actions { grid-column: 1 / span 5; }
  }
  @media (min-width: 1024px) {
    .hero__line--2 { padding-left: 0.95em; }
    .hero__scroll { display: inline-flex; grid-column: 1 / span 3; grid-row: 1; }
    .hero__lead { grid-column: 5 / span 4; grid-row: 1; }
    .hero__actions { grid-column: 9 / -1; grid-row: 1; justify-content: flex-end; }
  }

  /* Problem --------------------------------------------- */
  .problem__head { margin-bottom: 3rem; }
  .problem__list { display: grid; border-top: 1px solid var(--line); }
  .problem__item { display: grid; gap: .5rem; padding-block: 1.75rem; border-bottom: 1px solid var(--line); }
  .problem__item p:last-child { color: var(--fg-mute); }
  .problem__tag { color: var(--accent); }
  .problem__conclusion { margin-top: 3.5rem; font-size: var(--fs-h4); line-height: 1.7; }
  .problem__conclusion strong { font-weight: 700; background: linear-gradient(transparent 62%, color-mix(in oklab, var(--accent) 55%, transparent) 0); }
  @media (min-width: 768px) {
    .problem__item { grid-template-columns: 1fr 2fr; column-gap: var(--gutter); }
    .problem__item .problem__tag { grid-row: span 2; padding-top: .35rem; }
  }
  @media (min-width: 1024px) {
    .problem__head { grid-column: 1 / span 5; align-self: start; position: sticky; top: calc(var(--header-h) + 2rem); margin: 0; }
    .problem__list { grid-column: 6 / -1; }
    .problem__conclusion { grid-column: 6 / -1; }
  }

  /* Value ----------------------------------------------- */
  .value__statement {
    font-size: clamp(1.625rem, 1rem + 3vw, 4rem);
    font-weight: 700;
    line-height: 1.45;
    letter-spacing: 0.01em;
    max-width: 22em;
  }
  .value__statement .char { will-change: opacity; }
  .value__pillars { display: grid; gap: 2.5rem; margin-top: clamp(4rem, 8vw, 8rem); }
  .pillar { display: grid; gap: .75rem; padding-top: 1.25rem; border-top: 1px solid var(--line); }
  .pillar p:last-child { color: var(--fg-mute); }
  .pillar__en { font-family: var(--font-display); font-weight: 700; font-variation-settings: "wdth" 72; font-size: clamp(2.5rem, 2rem + 2.5vw, 4.5rem); line-height: 1; letter-spacing: -0.03em; color: var(--accent); }
  @media (min-width: 768px) { .value__pillars { grid-template-columns: repeat(3, 1fr); gap: var(--gutter); } }
  @media (min-width: 1024px) { .value__statement { grid-column: 1 / span 11; } }

  /* Services -------------------------------------------- */
  .services { background: var(--paper); position: relative; }
  .services__viewport { padding-block: var(--section); }
  .services__track { display: grid; gap: 1.25rem; padding-inline: var(--margin); }
  .services__intro { display: grid; align-content: start; gap: 1.5rem; padding-bottom: 2rem; }
  .services__intro .section-label { margin-bottom: 0; }
  .services__intro-text { color: var(--fg-mute); max-width: 28em; }

  .service {
    display: flex; flex-direction: column; gap: 1.25rem;
    padding: clamp(1.5rem, 3vw, 2.5rem);
    background: var(--ink); color: var(--paper);
    --fg-mute: color-mix(in oklab, var(--paper) 62%, var(--ink));
    --line: color-mix(in oklab, var(--paper) 18%, transparent);
  }
  .service__code { color: var(--accent); }
  .service__title { display: grid; gap: 1rem; }
  .service__en { font-family: var(--font-display); font-weight: 800; font-variation-settings: "wdth" 70; font-size: clamp(3rem, 2rem + 5vw, 7.5rem); line-height: .88; letter-spacing: -0.04em; }
  .service__jp { font-size: 1rem; font-weight: 700; }
  .service__desc { color: color-mix(in oklab, var(--paper) 84%, var(--ink)); }
  .service__meta { margin-top: auto; display: grid; gap: .75rem; padding-top: 1.25rem; border-top: 1px solid var(--line); font-size: .875rem; }
  .service__meta div { display: grid; grid-template-columns: 7.5rem 1fr; gap: 1rem; }
  .service__meta dt { color: var(--fg-mute); }
  .services__progress { display: none; }

  @media (min-width: 1024px) {
    .services.is-pinned .services__viewport { height: 100svh; padding-block: calc(var(--header-h) + 3rem) 3rem; display: flex; flex-direction: column; justify-content: center; overflow: hidden; }
    .services.is-pinned .services__track { display: flex; gap: var(--gutter); width: max-content; height: min(36rem, 100%); }
    .services.is-pinned .services__intro { width: 34vw; padding-right: 4vw; padding-bottom: 0; }
    .services.is-pinned .service { width: min(44vw, 40rem); }
    .services.is-pinned .service:nth-of-type(even) { background: var(--accent); color: var(--ink); --fg-mute: color-mix(in oklab, var(--ink) 70%, var(--accent)); --line: color-mix(in oklab, var(--ink) 25%, transparent); }
    .services.is-pinned .service:nth-of-type(even) .service__code { color: var(--ink); }
    .services.is-pinned .service:nth-of-type(even) .service__desc { color: var(--ink); }
    .services.is-pinned .services__progress { display: block; margin: 2.5rem var(--margin) 0; height: 2px; background: var(--line); }
    .services__progress span { display: block; height: 100%; background: var(--ink); transform-origin: left; transform: scaleX(0); }
    .services:not(.is-pinned) .services__track { grid-template-columns: repeat(2, 1fr); }
    .services:not(.is-pinned) .services__intro { grid-column: 1 / -1; }
  }
  @media (min-width: 768px) and (max-width: 1023.98px) {
    .services__track { grid-template-columns: repeat(2, 1fr); }
    .services__intro { grid-column: 1 / -1; }
  }

  /* Approach -------------------------------------------- */
  .approach__title {
    font-size: clamp(2.25rem, 1rem + 6vw, 7.5rem);
    line-height: 1.1;
    letter-spacing: -0.02em;
  }
  .approach__list { display: grid; gap: 2rem; margin-top: clamp(3.5rem, 7vw, 7rem); }
  .principle { display: grid; gap: .75rem; padding-top: 1.25rem; border-top: 2px solid var(--ink); }
  .principle__title { font-size: var(--fs-h4); }
  .principle p { color: var(--ink); }
  @media (min-width: 768px) { .approach__list { grid-template-columns: repeat(3, 1fr); gap: var(--gutter); } }
  @media (min-width: 1024px) { .approach__list { grid-column: 4 / -1; } }

  /* Process --------------------------------------------- */
  .process__head { margin-bottom: 3.5rem; display: grid; gap: 1.5rem; align-content: start; }
  .process__head .section-label { margin-bottom: 0; }
  .process__note { color: var(--fg-mute); max-width: 26em; }
  .process__steps { position: relative; }
  .process__line { position: absolute; left: 1.375rem; top: .5rem; bottom: .5rem; width: 1px; background: var(--line); }
  .process__line span { position: absolute; inset: 0; background: var(--accent); width: 3px; left: -1px; transform-origin: top; transform: scaleY(0); }
  .process__list { display: grid; gap: 0; }
  .step { display: grid; grid-template-columns: 2.75rem 1fr; gap: 1.25rem; padding-bottom: 3rem; }
  .step:last-child { padding-bottom: 0; }
  .step__num {
    position: relative; z-index: 1;
    display: grid; place-content: center;
    width: 2.75rem; height: 2.75rem; border-radius: 50%;
    background: var(--bg); border: 1px solid var(--fg);
    font-family: var(--font-display); font-weight: 600; font-size: .8125rem;
    transition: background-color .4s var(--ease-out), border-color .4s var(--ease-out);
  }
  .step.is-active .step__num { background: var(--accent); border-color: var(--accent); }
  .step__body { display: grid; gap: .5rem; padding-top: .35rem; }
  .step__title { font-family: var(--font-display); font-size: clamp(1.75rem, 1.2rem + 2vw, 3rem); font-weight: 700; font-variation-settings: "wdth" 80; letter-spacing: -0.02em; line-height: 1; display: flex; flex-wrap: wrap; align-items: baseline; gap: .25rem .75rem; }
  .step__title span { font-family: var(--font-body); font-size: 1rem; letter-spacing: .02em; }
  .step__time { color: var(--fg-mute); }
  .step__body p:last-child { color: color-mix(in oklab, var(--fg) 78%, var(--bg)); max-width: 34em; }
  @media (min-width: 1024px) {
    .process__head { grid-column: 1 / span 4; position: sticky; top: calc(var(--header-h) + 2rem); align-self: start; margin: 0; }
    .process__steps { grid-column: 6 / -1; }
  }

  /* Cases ----------------------------------------------- */
  .cases__head { margin-bottom: clamp(3rem, 6vw, 5rem); display: grid; gap: 1rem; }
  .cases__head .section-label { margin-bottom: .5rem; }
  .cases__note { color: var(--fg-mute); font-size: .875rem; }
  .cases__grid { display: grid; gap: clamp(3rem, 6vw, 5rem) var(--gutter); }
  .case__trigger { display: grid; gap: 1.25rem; width: 100%; text-align: left; color: inherit; cursor: pointer; }
  .case__media { position: relative; display: block; overflow: hidden; aspect-ratio: 4 / 5; background: color-mix(in oklab, var(--paper) 10%, var(--ink)); }
  .case__media img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.02); transition: transform 1.1s var(--ease-out), filter .6s; }
  .case__view {
    position: absolute; left: 1rem; bottom: 1rem;
    font-family: var(--font-display); font-size: .8125rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
    padding: .5rem .875rem; background: var(--accent); color: var(--ink);
  }
  .case__info { display: grid; gap: .5rem; }
  .case__client { color: var(--accent); }
  .case__title { font-size: clamp(1.25rem, 1rem + 1vw, 1.875rem); font-weight: 700; line-height: 1.4; }
  .case__tags { color: var(--fg-mute); }
  .case__trigger:focus-visible { outline-offset: 8px; }
  @media (hover: hover) and (pointer: fine) {
    .case__view { opacity: 0; transform: translateY(.5rem); transition: opacity .4s, transform .5s var(--ease-out); }
    .case__trigger:hover .case__media img { transform: scale(1.07); }
    .case__trigger:hover .case__title { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 2px; text-underline-offset: .2em; }
    .cases.has-cursor .case__trigger { cursor: none; }
    .case__trigger:focus-visible .case__view { opacity: 1; transform: none; }
  }
  @media (min-width: 768px) {
    .cases__grid { grid-template-columns: repeat(12, 1fr); align-items: start; }
    .case--wide { grid-column: span 7; }
    .case--tall { grid-column: span 5; }
    .case--wide .case__media { aspect-ratio: 4 / 3; }
    .case--tall .case__media { aspect-ratio: 3 / 4; }
    .cases__grid > :nth-child(2) { margin-top: clamp(6rem, 12vw, 12rem); }
    .cases__grid > :nth-child(3) { margin-top: calc(-1 * clamp(3rem, 8vw, 8rem)); }
  }
  @media (min-width: 1024px) {
    .cases__head { grid-column: 1 / span 7; }
  }

  .cursor {
    position: fixed; left: 0; top: 0; z-index: 60; pointer-events: none;
    width: 6rem; height: 6rem; margin: -3rem 0 0 -3rem; border-radius: 50%;
    background: var(--accent); color: var(--ink);
    display: none; place-content: center;
    font-family: var(--font-display); font-weight: 700; font-size: .875rem; letter-spacing: .04em; text-transform: uppercase;
    transform: scale(0);
  }
  .cases.has-cursor .cursor { display: grid; }

  /* Case dialog */
  .case-dialog {
    margin: 0 0 0 auto; padding: 0; border: 0;
    width: min(100%, 44rem); max-width: 100%; height: 100dvh; max-height: 100dvh;
    background: var(--paper); color: var(--ink);
  }
  .case-dialog::backdrop { background: color-mix(in oklab, var(--ink) 70%, transparent); }
  .case-dialog[open] { animation: dialog-in .6s var(--ease-out); }
  @keyframes dialog-in { from { transform: translateX(100%); } }
  .case-dialog__inner { display: grid; gap: 2rem; padding: clamp(1.5rem, 4vw, 3.5rem); padding-bottom: calc(clamp(1.5rem, 4vw, 3.5rem) + env(safe-area-inset-bottom)); }
  .case-dialog__close { justify-self: end; display: inline-flex; gap: .5rem; align-items: center; min-height: 2.75rem; padding-inline: 1rem; border: 1px solid var(--ink); border-radius: 999px; font-family: var(--font-display); font-weight: 600; font-size: .875rem; }
  .case-dialog__close:hover { background: var(--ink); color: var(--paper); }
  .case-dialog__content { display: grid; gap: 1.5rem; }
  .case-dialog__content .label { color: var(--accent); }
  .case-dialog__media { aspect-ratio: 16 / 10; overflow: hidden; }
  .case-dialog__media img { width: 100%; height: 100%; object-fit: cover; }
  .case-dialog__title { font-size: clamp(1.625rem, 1.2rem + 2vw, 2.5rem); line-height: 1.35; }
  .case-dialog__grid { display: grid; gap: 1.25rem; }
  .case-dialog__grid div { display: grid; gap: .25rem; padding-top: 1rem; border-top: 1px solid var(--line); }
  .case-dialog__grid dt { font-family: var(--font-display); font-weight: 700; font-size: .8125rem; letter-spacing: .06em; text-transform: uppercase; }
  .case-dialog__grid dd { margin: 0; color: #3b3a36; }
  .case-dialog .btn { justify-self: start; }
  @media (min-width: 640px) { .case-dialog__grid div { grid-template-columns: 7rem 1fr; gap: 1rem; } }

  /* Results --------------------------------------------- */
  .results__head { margin-bottom: clamp(3rem, 6vw, 5rem); display: grid; gap: 1rem; }
  .results__head .section-label { margin-bottom: .5rem; }
  .results__note { color: var(--fg-mute); font-size: .875rem; max-width: 30em; }
  .results__list { display: grid; border-top: 1px solid var(--ink); }
  .metric { display: grid; gap: .5rem; padding-block: 1.75rem; border-bottom: 1px solid var(--line); }
  .metric__value {
    font-family: var(--font-display); font-weight: 800; font-variation-settings: "wdth" 68;
    font-size: clamp(4.5rem, 3rem + 7vw, 10rem); line-height: .85; letter-spacing: -0.045em;
    font-variant-numeric: tabular-nums;
    display: flex; align-items: flex-start;
  }
  .metric__unit { font-size: .42em; color: var(--accent); margin-left: .06em; margin-top: .1em; letter-spacing: 0; }
  .metric__label { font-weight: 700; line-height: 1.5; }
  .metric__label span { font-weight: 400; color: var(--fg-mute); font-size: .875rem; }
  @media (min-width: 768px) {
    .results__list { grid-template-columns: repeat(2, 1fr); column-gap: var(--gutter); }
  }
  @media (min-width: 1024px) {
    .results__head { grid-column: 1 / span 6; }
    .results__list { grid-template-columns: repeat(4, 1fr); border-bottom: 1px solid var(--line); }
    .metric { border-bottom: 0; padding-right: 1rem; border-right: 1px solid var(--line); }
    .metric:last-child { border-right: 0; }
  }

  /* FAQ ------------------------------------------------- */
  .faq { padding-top: 0; }
  .faq__head { margin-bottom: 2.5rem; }
  .faq__list { border-top: 1px solid var(--ink); }
  .faq__item { border-bottom: 1px solid var(--line); }
  .faq__item summary {
    list-style: none; cursor: pointer;
    display: flex; justify-content: space-between; align-items: center; gap: 1.5rem;
    min-height: 4.5rem; padding-block: 1.25rem;
    font-size: var(--fs-h4); font-weight: 700; line-height: 1.5;
  }
  .faq__item summary::-webkit-details-marker { display: none; }
  .faq__icon { flex: none; position: relative; width: 2.25rem; height: 2.25rem; border-radius: 50%; border: 1px solid var(--ink); transition: background-color .3s, border-color .3s; }
  .faq__icon::before, .faq__icon::after { content: ""; position: absolute; left: 50%; top: 50%; width: .75rem; height: 1.5px; background: currentColor; translate: -50% -50%; transition: rotate .45s var(--ease-out); }
  .faq__icon::after { rotate: 90deg; }
  .faq__item[open] .faq__icon { background: var(--accent); border-color: var(--accent); }
  .faq__item[open] .faq__icon::after { rotate: 0deg; }
  .faq__item summary:hover .faq__icon { border-color: var(--accent); }
  .faq__answer { overflow: hidden; }
  .faq__answer p { padding-bottom: 1.75rem; color: color-mix(in oklab, var(--fg) 76%, var(--bg)); max-width: 40em; }
  @media (min-width: 1024px) {
    .faq__head { grid-column: 1 / span 4; }
    .faq__list { grid-column: 5 / -1; }
  }

  /* Contact --------------------------------------------- */
  .contact__head { display: grid; gap: 1.5rem; align-content: start; margin-bottom: 3.5rem; }
  .contact__head .section-label { margin-bottom: 0; }
  .contact__title {
    font-family: var(--font-display); font-weight: 800; font-variation-settings: "wdth" 70;
    font-size: clamp(4.5rem, 2rem + 12vw, 13rem); line-height: .85; letter-spacing: -0.05em;
    color: var(--accent);
  }
  .contact__lead { font-size: var(--fs-h4); line-height: 1.7; }
  .contact__points { display: grid; gap: .5rem; color: var(--fg-mute); font-size: .9375rem; }
  .contact__points li { display: flex; gap: .75rem; align-items: baseline; }
  .contact__points li::before { content: "→"; font-family: var(--font-display); color: var(--accent); }

  .form { display: grid; gap: 1.75rem; }
  .form__demo { padding: 1rem 1.25rem; border: 1px dashed color-mix(in oklab, var(--paper) 45%, transparent); font-size: .875rem; line-height: 1.7; }
  .form__demo strong { color: var(--accent); }
  .form__errors { padding: 1rem 1.25rem; background: var(--accent); color: var(--ink); font-size: .9375rem; font-weight: 500; }
  .form__errors ul { margin-top: .5rem; padding-left: 1.25rem; }
  .form__errors a { color: var(--ink); }
  .form__status { font-weight: 700; }
  .form__status:empty { display: none; }
  .form__status.is-success { padding: 1.25rem; border: 1px solid var(--accent); line-height: 1.7; }

  @media (min-width: 1024px) {
    .contact__head { grid-column: 1 / span 6; position: sticky; top: calc(var(--header-h) + 2rem); align-self: start; margin: 0; }
    .form { grid-column: 8 / -1; }
  }

  /* Footer ---------------------------------------------- */
  .site-footer { background: var(--paper); color: var(--ink); padding-top: clamp(4rem, 8vw, 7rem); padding-bottom: calc(1.5rem + env(safe-area-inset-bottom)); overflow: hidden; }
  .footer__cols { display: grid; gap: 2.5rem var(--gutter); font-size: .9375rem; }
  .footer__cols .label { color: var(--mute); margin-bottom: .75rem; }
  .footer__cols address { font-style: normal; }
  .footer__cols ul { display: grid; gap: .25rem; }
  .footer__wordmark {
    margin-top: clamp(3rem, 8vw, 6rem);
    font-family: var(--font-display); font-weight: 800; font-variation-settings: "wdth" 62;
    font-size: 15.2vw; line-height: .8; letter-spacing: -0.05em;
    white-space: nowrap;
    margin-inline: -0.03em;
  }
  .footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; margin-top: 1.5rem; padding-top: 1.25rem; border-top: 1px solid var(--line); font-family: var(--font-display); font-size: .8125rem; }
  @media (min-width: 768px) { .footer__cols { grid-template-columns: repeat(2, 1fr); } }
  @media (min-width: 1024px) {
    .footer__cols { grid-template-columns: repeat(4, 1fr); }
    .footer__wordmark { font-size: 14.6vw; }
  }
}

@layer utilities {
  .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; }

  /* Pre-hide hero items only when JS + motion are available; main.js reveals them. */
  @media (prefers-reduced-motion: no-preference) {
    .js.motion-ready [data-hero-item], .js.motion-ready [data-hero-arrow], .js.motion-ready [data-hero-split] { visibility: hidden; }
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

/* 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; }

@layer sections {
  .case__media { aspect-ratio: 4 / 3; }
  .service__en { overflow-wrap: normal; font-size: clamp(2rem, 6.8vw, 6rem); }
  @media (max-width: 47.99rem) {
    .value__statement { font-size: clamp(1.5rem, 6.2vw, 2rem); line-height: 1.5; }
  }
}
