/**
 * THETA MV — shared hero stage layers
 * top page  : 3D AI office (theta-mv-robot3d.js)
 * About page: wireframe prism you can cut (theta-mv-prism.js)
 */

/* No stacking context here: the MV canvas has to be able to sit below
   .tx_pageFolds (z-index:-1) so the scroll slits stay on top of it */
.tx_heroStage {
  position: relative;
  z-index: auto !important;
  pointer-events: auto !important;
  user-select: none;
  -webkit-user-select: none;
  /* pan-y: FV 上からでも縦スクロール可能（none だと top/about が止まっていた） */
  touch-action: pan-y;
  cursor: default;
}

.tx_heroStage .tx_theta_prism,
.tx_heroStage canvas[data-theta-prism],
.tx_heroStage .tx_theta_prismCut,
.tx_heroStage .tx_theta_prismHit {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.tx_heroStage .tx_theta_prism,
.tx_heroStage canvas[data-theta-prism] {
  z-index: 1;
  pointer-events: none !important;
}

/* Top page: below .tx_pageFolds (z-index:-1) so the scroll slits cross over the
   office. This canvas is 2D on purpose — theta-mv-robot3d.js renders WebGL
   offscreen and blits, because a WebGL layer at a negative z-index is
   composited behind the page background and disappears. */
.tx_heroStage[data-theta-mv="robot3d"] canvas[data-theta-prism] {
  z-index: -2;
}

.tx_heroStage .tx_theta_prismCut {
  z-index: 3;
  pointer-events: none !important;
}

/* Dedicated drag layer — above copy; leave bottom for Scroll control.
   pan-y keeps vertical scroll; cutting still works via pointer handlers. */
.tx_heroStage .tx_theta_prismHit {
  z-index: 5;
  top: 0;
  right: 0;
  bottom: 5.5rem;
  left: 0;
  width: auto;
  height: auto;
  pointer-events: auto !important;
  touch-action: pan-y;
  cursor: default;
  background: transparent;
}

/* About prism: allow intentional cut gestures without locking page scroll */
.tx_heroStage[data-theta-mv="prism"].is-cutting,
.tx_heroStage[data-theta-mv="prism"].is-cutting .tx_theta_prismHit {
  touch-action: none;
}

.tx_heroStage_inset {
  position: relative;
  z-index: 2;
  pointer-events: none !important;
  user-select: none !important;
  -webkit-user-select: none !important;
}

.tx_heroStage_inset a,
.tx_heroStage_inset button {
  pointer-events: auto !important;
  cursor: pointer;
  position: relative;
  z-index: 6;
}

/* the prism is cut by dragging, so hint at it */
.tx_heroStage[data-theta-mv="prism"],
.tx_heroStage[data-theta-mv="prism"] .tx_theta_prismHit {
  cursor: crosshair;
}

.tx_heroStage.is-cutting,
.tx_heroStage.is-cutting * {
  cursor: crosshair !important;
  user-select: none !important;
  -webkit-user-select: none !important;
}

/* AX GROWTH PARTNER — single block, right-aligned, slide-in only */
.tx_heroStage_copyEn {
  width: 100%;
}

/* [data-tx-dup] の overflow:clip が光彩を切るので TOP MV だけ外す */
.tx_heroStage[data-theta-mv="robot3d"] .tx_heroStage_copyEn,
.tx_heroStage[data-theta-mv="robot3d"] .tx_heroStage_copyEn[data-tx-dup] {
  overflow: visible !important;
}

.tx_heroStage_copyEn .tx_heroStage_copy {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: flex-start !important;
  width: 100%;
}

.tx_heroStage_copyEn .tx_heroStage_word {
  overflow: hidden;
  width: auto !important;
  max-width: 100%;
  margin-inline-start: auto;
}

/* TOP MV: text-shadow 光彩が overflow:hidden で欠けないよう余白を確保 */
.tx_heroStage[data-theta-mv="robot3d"] .tx_heroStage_copyEn .tx_heroStage_word {
  overflow: visible;
  padding: 1.2rem 1.8rem;
  margin-block: -1.2rem;
  margin-inline: auto -1.8rem;
}

.tx_heroStage[data-theta-mv="robot3d"] .tx_heroStage_enLine,
.tx_heroStage[data-theta-mv="robot3d"] .tx_heroStage_enLine [data-tx-hero="path"] {
  overflow: visible;
}

.tx_heroStage_enLine {
  display: block;
  font-family: "Archivo Black", Inter, "Helvetica Neue", Arial, sans-serif;
  font-weight: 400;
  font-style: normal;
  line-height: 0.95;
  letter-spacing: -0.03em;
  color: var(--color-black, #222220);
  white-space: nowrap;
  text-align: right;
}

.tx_heroStage_enLine [data-tx-hero="path"] {
  display: inline-block;
  will-change: transform;
  margin: 0;
  padding: 0;
}

@media screen and (max-width: 47.938em) {
  .tx_heroStage_enLine {
    font-size: clamp(1.15rem, 5.2vw, 1.55rem);
  }
}

@media screen and (min-width: 48em) {
  .tx_heroStage_enLine {
    font-size: clamp(2.8rem, 5.6vw, 5.6rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  .tx_heroStage {
    cursor: default;
    touch-action: auto;
  }
}
