/* ============================================================
   Phasera — activetheory-inspired dark WebGL edition
   ============================================================ */

:root {
  --bg: #04060c;
  --bg-2: #0b1e3f;
  --ink: #eaf1fb;
  --dim: #aebfd9; /* body copy — lifted for readability on the dark field */
  --dim-2: #6d80a3;
  --accent: #6fa8ff;
  --accent-2: #3c66d9;
  --accent-3: #9cc4ff;
  --line: rgba(140, 170, 220, 0.14);
  --pill-bg: rgba(10, 18, 34, 0.55);
  --pill-line: rgba(150, 180, 230, 0.16);
  --font-en: 'Space Grotesk', 'Inter', -apple-system, 'Helvetica Neue', sans-serif;
  --font-jp: 'Noto Sans JP', 'Hiragino Kaku Gothic ProN', 'Yu Gothic', sans-serif;
  --font-mono: 'Space Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: auto; }
html, body { background: var(--bg); }
body {
  font-family: var(--font-jp);
  color: var(--ink);
  line-height: 1.75;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  cursor: none;
}
@media (pointer: coarse), (max-width: 820px) { body { cursor: auto; } }
body.locked { overflow: hidden; height: 100vh; }

a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
img { max-width: 100%; display: block; }
::selection { background: rgba(111, 168, 255, 0.35); color: #fff; }

/* ---------- fixed WebGL stage ---------- */
#gl {
  position: fixed; inset: 0; z-index: 0;
  width: 100%; height: 100%;
  display: block;
  pointer-events: none;
}
.grain {
  position: fixed; inset: -60px; z-index: 3; pointer-events: none;
  opacity: 0.05; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 0.9s steps(2) infinite;
}
@keyframes grain { 50% { transform: translate(12px, -8px); } }
.vig {
  position: fixed; inset: 0; z-index: 2; pointer-events: none;
  background: radial-gradient(ellipse 120% 90% at 50% 45%, transparent 55%, rgba(2, 5, 12, 0.55) 100%);
}

/* ---------- custom cursor ---------- */
.cur-dot, .cur-ring {
  position: fixed; top: 0; left: 0; z-index: 300; pointer-events: none;
  border-radius: 50%;
  will-change: transform;
}
.cur-dot { width: 6px; height: 6px; background: var(--accent-3); margin: -3px 0 0 -3px; }
.cur-ring {
  width: 34px; height: 34px; margin: -17px 0 0 -17px;
  border: 1px solid rgba(156, 196, 255, 0.5);
  transition: width 0.25s var(--ease-out), height 0.25s var(--ease-out),
    margin 0.25s var(--ease-out), background 0.25s, border-color 0.25s;
  display: grid; place-items: center;
}
.cur-ring span {
  font-family: var(--font-mono); font-size: 8px; letter-spacing: 0.14em;
  color: var(--bg); opacity: 0; text-transform: uppercase; transition: opacity 0.2s;
}
.cur-ring.drag {
  width: 74px; height: 74px; margin: -37px 0 0 -37px;
  background: rgba(156, 196, 255, 0.92); border-color: transparent;
}
.cur-ring.drag span { opacity: 1; }
.cur-ring.link { width: 52px; height: 52px; margin: -26px 0 0 -26px; border-color: var(--accent); }
@media (pointer: coarse), (max-width: 820px) { .cur-dot, .cur-ring { display: none; } }

/* ---------- preloader ---------- */
.loader {
  position: fixed; inset: 0; z-index: 400;
  background: var(--bg);
  display: grid; place-items: center;
  transition: opacity 0.9s var(--ease-out), visibility 0.9s;
}
.loader.done { opacity: 0; visibility: hidden; }
.loader .inner { text-align: center; }
.loader .wd {
  font-family: var(--font-en); font-weight: 700;
  font-size: clamp(22px, 4vw, 34px); letter-spacing: 0.42em; text-indent: 0.42em;
  color: var(--ink);
}
.loader .pct {
  font-family: var(--font-mono); font-size: clamp(48px, 9vw, 96px);
  color: var(--accent-3); line-height: 1; margin: 18px 0 10px;
  font-variant-numeric: tabular-nums;
}
.loader .pct sup { font-size: 0.32em; color: var(--dim); }
.loader .bar {
  width: min(260px, 60vw); height: 1px; background: rgba(140, 170, 220, 0.18);
  margin: 0 auto; position: relative; overflow: hidden;
}
.loader .bar i {
  position: absolute; inset: 0; transform-origin: 0 50%; transform: scaleX(0);
  background: var(--accent); display: block;
}
.loader .st {
  margin-top: 14px; font-family: var(--font-mono); font-size: 9px;
  letter-spacing: 0.3em; color: var(--dim-2); text-transform: uppercase;
}

/* ---------- pill nav — anchored top-right, tethered to the corner
   by a hairline (activetheory signature), deforms with scroll velocity ---------- */
.nav {
  position: fixed; top: 22px; right: 26px;
  z-index: 200;
  display: flex; align-items: center; gap: 4px;
  padding: 8px;
  border-radius: 999px;
  background: var(--pill-bg);
  border: 1px solid var(--pill-line);
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  box-shadow: 0 8px 40px rgba(2, 6, 16, 0.45);
  transform-origin: 100% 0;
  will-change: transform;
}
.nav::before {
  content: '';
  position: absolute; top: -22px; right: 34px;
  width: 1px; height: 22px;
  background: rgba(150, 180, 230, 0.28);
}
.nav .brand {
  display: flex; align-items: center; gap: 9px;
  padding: 6px 14px 6px 8px; border-radius: 999px;
}
.nav .brand img { width: 22px; height: 22px; }
.nav .brand b {
  font-family: var(--font-en); font-weight: 700; font-size: 12px; letter-spacing: 0.3em;
}
.nav ul { display: flex; align-items: center; }
.nav ul a {
  display: block; padding: 8px 13px; border-radius: 999px;
  font-size: 12px; color: var(--dim);
  transition: color 0.25s, background 0.25s;
}
.nav ul a sup {
  font-family: var(--font-mono); font-size: 8px; color: var(--accent-2);
  margin-right: 5px;
}
.nav ul a:hover, .nav ul a.on { color: var(--ink); background: rgba(140, 175, 235, 0.09); }
.nav .cta {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 18px; border-radius: 999px;
  background: var(--ink); color: #0a1526;
  font-size: 12px; font-weight: 700;
  transition: background 0.25s, transform 0.25s;
}
.nav .cta:hover { background: var(--accent-3); transform: scale(1.03); }
.nav .cta i {
  width: 6px; height: 6px; border-radius: 50%; background: var(--accent-2);
  animation: pulse 2.2s infinite;
}
@keyframes pulse { 50% { opacity: 0.3; } }
.burger { display: none; }
@media (max-width: 1080px) {
  .nav ul { display: none; }
  .burger {
    display: grid; place-items: center; gap: 4px;
    width: 38px; height: 38px; border-radius: 50%;
    background: transparent; border: 1px solid var(--pill-line); cursor: pointer;
    padding: 0 10px;
  }
  .burger i { width: 16px; height: 1.5px; background: var(--ink); display: block; transition: transform .3s; }
}

/* fullscreen menu */
.menu {
  position: fixed; inset: 0; z-index: 350;
  background: rgba(4, 8, 18, 0.92); backdrop-filter: blur(24px);
  display: grid; place-content: center; gap: 6px;
  opacity: 0; visibility: hidden; transition: opacity 0.4s, visibility 0.4s;
}
.menu.open { opacity: 1; visibility: visible; }
.menu a {
  font-family: var(--font-jp); font-size: clamp(22px, 5vw, 34px); font-weight: 600;
  padding: 6px 0; color: var(--dim); transition: color 0.25s;
}
.menu a:hover { color: var(--ink); }
.menu a sup { font-family: var(--font-mono); font-size: 10px; color: var(--accent-2); margin-right: 12px; }
.menu .m-cta { color: var(--accent-3); }
.menu .m-close {
  position: absolute; top: 26px; right: 26px;
  width: 44px; height: 44px; border-radius: 50%;
  background: transparent; border: 1px solid var(--pill-line); color: var(--ink);
  font-size: 16px; cursor: pointer;
}

/* ---------- scroll pill (velocity-reactive, AT signature) ---------- */
.scroll-pill {
  position: fixed; bottom: 22px; right: 26px; z-index: 200;
  width: 30px; height: 52px; border-radius: 999px;
  border: 1px solid var(--pill-line);
  background: var(--pill-bg);
  backdrop-filter: blur(14px);
  display: grid; place-items: center;
  will-change: transform;
}
.scroll-pill i {
  width: 4px; height: 10px; border-radius: 4px; background: var(--accent-3);
  animation: sp 1.8s var(--ease-out) infinite;
}
@keyframes sp {
  0% { transform: translateY(-8px); opacity: 0; }
  40% { opacity: 1; }
  100% { transform: translateY(10px); opacity: 0; }
}
@media (max-width: 820px) { .scroll-pill { right: 14px; bottom: 86px; } }

/* ---------- ask pill (AI-chat homage) ---------- */
.ask-pill {
  position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%);
  z-index: 200;
  display: flex; align-items: center; gap: 12px;
  padding: 12px 20px; min-width: min(420px, 78vw);
  border-radius: 999px;
  background: var(--pill-bg); border: 1px solid var(--pill-line);
  backdrop-filter: blur(18px) saturate(1.3);
  box-shadow: 0 8px 40px rgba(2, 6, 16, 0.45);
  transition: border-color 0.3s, transform 0.3s var(--ease-out);
}
.ask-pill:hover { border-color: rgba(156, 196, 255, 0.45); transform: translateX(-50%) scale(1.02); }
.ask-pill .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent); box-shadow: 0 0 12px var(--accent);
  animation: pulse 2.4s infinite; flex: none;
}
.ask-pill .ph { font-size: 12.5px; color: var(--dim); flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ask-pill .ph em { color: var(--ink); font-style: normal; }
.ask-pill .arr { font-family: var(--font-mono); color: var(--accent-3); font-size: 13px; flex: none; }
@media (max-width: 820px) { .ask-pill { bottom: 16px; min-width: min(320px, 82vw); } }

/* ---------- content column ---------- */
main { position: relative; z-index: 10; }
.wrap { width: min(1200px, 92vw); margin: 0 auto; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.3em;
  text-transform: uppercase; color: var(--accent-3);
}
.eyebrow::before { content: ''; width: 26px; height: 1px; background: var(--accent-2); }

h2 {
  font-size: clamp(30px, 4.6vw, 54px); font-weight: 700; line-height: 1.3;
  letter-spacing: 0.01em; margin: 18px 0 10px;
}
/* heading line-breaks: wrap only between phrases, on every viewport */
h1, h2, h3 { word-break: auto-phrase; }
.nb { display: inline-block; } /* phrase unit — never breaks mid-phrase */
h2 em, h3 em, .lede em, p em { font-style: normal; color: var(--accent-3); }
/* technical (mono/sans) vs editorial (serif) tension — AT-style */
h2 em, .quote em, .hero-sub h1 em { font-family: 'Shippori Mincho', 'Hiragino Mincho ProN', serif; font-weight: 600; }
.lede { color: var(--dim); max-width: 44em; }

/* reveal */
.rv { opacity: 0; transform: translateY(36px); transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out); }
.rv.in { opacity: 1; transform: none; }

/* ---------- HERO — wordmark floating over the luminous particle core ---------- */
#hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column;
  padding: 15vh 0 13vh;
  overflow: hidden;
}
.hero-word {
  position: relative;
  width: 100%;
  margin: auto 0;
  user-select: none;
  pointer-events: none;
}
.hero-word svg { display: block; width: min(1400px, 94vw); height: auto; margin: 0 auto; overflow: visible; }
.hero-word text {
  font-family: var(--font-en); font-weight: 700; letter-spacing: 0.01em;
  fill: var(--ink);
}
.hero-sub {
  display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between;
  gap: 18px 40px;
  width: min(1400px, 94vw); margin: 4vh auto 0;
}
.hero-sub h1 {
  font-size: clamp(17px, 2.1vw, 25px); font-weight: 600; line-height: 2;
  letter-spacing: 0.06em;
}
.hero-sub h1 .ln { display: block; overflow: hidden; }
.hero-sub h1 .ln span { display: inline-block; transform: translateY(110%); transition: transform 1.1s var(--ease-out); }
body.ready .hero-sub h1 .ln span { transform: none; }
.hero-meta {
  display: flex; gap: 34px;
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.16em;
  color: var(--dim); text-transform: uppercase;
}
.hero-meta b { display: block; color: var(--accent-3); font-weight: 400; margin-bottom: 3px; }
.hero-tag {
  align-self: center;
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.34em;
  text-transform: uppercase; color: var(--dim);
  display: flex; align-items: center; gap: 14px;
  white-space: nowrap; max-width: 94vw; overflow: hidden;
}
.hero-tag i { width: 40px; height: 1px; background: var(--dim-2); display: block; flex: none; }
.hero-sub h1 .h1-dim { color: var(--dim); font-size: 0.78em; font-weight: 400; }
@media (max-width: 820px) {
  .hero-sub { flex-direction: column; align-items: flex-start; }
  .hero-meta { flex-wrap: wrap; gap: 16px 26px; }
}

/* hero word intro */
.hero-word .wl { opacity: 0; transform: translateY(0.35em); transition: opacity 1s var(--ease-out), transform 1.2s var(--ease-out); }
body.ready .hero-word .wl { opacity: 1; transform: none; }

/* ---------- generic chapter (dark editorial) ---------- */
.chapter { position: relative; padding: 21vh 0; }
.chapter .head { margin-bottom: 8vh; }
.outline-no {
  position: absolute; top: 6vh; right: 2vw; z-index: -1;
  font-family: var(--font-en); font-weight: 700;
  font-size: clamp(120px, 22vw, 320px); line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(140, 175, 235, 0.1);
  pointer-events: none; user-select: none;
}

/* leaks */
.leak-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.leak {
  background: rgba(7, 12, 24, 0.72); backdrop-filter: blur(6px);
  padding: clamp(26px, 4vw, 52px);
  position: relative; overflow: hidden;
  transition: background 0.4s;
}
.leak:hover { background: rgba(12, 22, 44, 0.82); }
.leak .no {
  font-family: var(--font-mono); font-size: 10px; color: var(--accent-2); letter-spacing: 0.26em;
}
.leak h3 { font-size: clamp(19px, 2.2vw, 26px); font-weight: 700; line-height: 1.55; margin: 14px 0 10px; }
.leak p { font-size: 14px; color: var(--dim); }
.leak .metric {
  margin-top: 22px; display: flex; align-items: baseline; gap: 12px;
}
.leak .metric b {
  font-family: var(--font-en); font-size: clamp(24px, 2.6vw, 34px); color: var(--accent-3);
  font-weight: 700; letter-spacing: 0.02em;
}
.leak .metric span { font-family: var(--font-mono); font-size: 10px; color: var(--dim-2); letter-spacing: 0.14em; }
@media (max-width: 820px) { .leak-grid { grid-template-columns: 1fr; } }

/* ---------- WORKS (pinned GL stage) ---------- */
#works { position: relative; height: 560vh; }
.works-pin {
  position: sticky; top: 0; height: 100vh; height: 100svh;
  overflow: hidden;
  display: flex; flex-direction: column; justify-content: space-between;
}
.works-pin .whead {
  padding-top: 96px;
  width: min(1400px, 94vw); margin: 0 auto;
  display: flex; justify-content: space-between; align-items: flex-start;
  pointer-events: none;
}
.works-pin .whead .eyebrow { pointer-events: auto; }
.wcount { color: var(--dim-2); margin-left: 8px; }
.works-hint {
  font-family: var(--font-mono); font-size: 9px; color: var(--dim-2);
  letter-spacing: 0.3em; text-transform: uppercase; text-align: right;
}
.works-stage {
  position: absolute; inset: 0; z-index: 5;
  touch-action: pan-y;
}
.works-ui {
  position: relative; z-index: 6;
  width: min(1400px, 94vw); margin: 0 auto;
  padding-bottom: 88px;
  display: flex; justify-content: space-between; align-items: flex-end; gap: 30px;
  pointer-events: none;
}
.works-ui > * { pointer-events: auto; }

.w-title { min-height: 120px; }
.w-title .idx { font-family: var(--font-mono); font-size: 11px; color: var(--accent-3); letter-spacing: 0.2em; }
.w-title h3 {
  font-family: var(--font-en); font-weight: 700;
  font-size: clamp(34px, 5vw, 64px); line-height: 1.02; letter-spacing: 0.01em;
  margin: 8px 0 6px;
}
.w-title h3 .wl-ln { display: block; overflow: hidden; }
.w-title h3 .wl-ln span { display: inline-block; transform: translateY(0); transition: transform 0.7s var(--ease-out), opacity .5s; }
.w-title h3.out .wl-ln span { transform: translateY(105%); opacity: 0; transition-duration: 0.35s; }
.w-title .sub { font-size: 12.5px; color: var(--dim); }
.w-title .desc { font-size: 12.5px; color: var(--dim-2); max-width: 34em; }

.w-filter {
  display: flex; flex-direction: column; gap: 4px; align-items: flex-end;
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em;
}
.w-filter b { font-family: var(--font-jp); font-size: 11px; font-weight: 500; color: var(--dim-2); margin-bottom: 6px; }
.w-filter a { color: var(--dim); padding: 3px 0; transition: color 0.25s; }
.w-filter a:hover, .w-filter a.on { color: var(--accent-3); }

.w-pager { display: flex; align-items: center; gap: 16px; }
.w-pager button {
  width: 44px; height: 44px; border-radius: 50%;
  background: transparent; border: 1px solid var(--pill-line); color: var(--ink);
  font-size: 15px; cursor: pointer; transition: background 0.25s, border-color 0.25s;
}
.w-pager button:hover { background: rgba(140, 175, 235, 0.12); border-color: var(--accent-2); }
.w-progress {
  position: absolute; left: 50%; bottom: 34px; transform: translateX(-50%);
  width: min(220px, 30vw); height: 1px; background: rgba(140, 170, 220, 0.16); z-index: 6;
}
.w-progress i { position: absolute; inset: 0; background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); }

/* DOM fallback list when WebGL is unavailable */
.works-fallback { display: none; width: min(1200px, 92vw); margin: 0 auto; padding: 120px 0; }
body.no-webgl #works { height: auto; }
body.no-webgl .works-pin { position: static; height: auto; }
body.no-webgl .works-ui, body.no-webgl .works-stage { display: none; }
body.no-webgl .works-fallback { display: grid; gap: 1px; }
.works-fallback article { border: 1px solid var(--line); padding: 30px; }
.works-fallback h3 { font-family: var(--font-en); font-size: 28px; }
.works-fallback span { color: var(--dim); font-size: 13px; }

@media (max-width: 820px) {
  .works-ui { flex-direction: column; align-items: flex-start; padding-bottom: 96px; }
  .w-filter { display: none; }
  .works-hint { display: none; }
}

/* ---------- PATH ---------- */
.path-list { border-top: 1px solid var(--line); margin-top: 7vh; }
.path-row {
  display: grid; grid-template-columns: 140px 1fr 1.1fr auto; gap: 26px;
  align-items: baseline;
  padding: 34px 0; border-bottom: 1px solid var(--line);
  transition: background 0.3s; position: relative;
}
.path-row:hover { background: rgba(12, 22, 44, 0.4); }
.path-row .no { font-family: var(--font-mono); font-size: 10px; color: var(--accent-2); letter-spacing: 0.2em; }
.path-row h3 { font-size: clamp(17px, 1.8vw, 21px); font-weight: 700; }
.path-row h3 small { display: block; font-size: 11px; color: var(--dim-2); font-weight: 400; margin-top: 4px; }
.path-row .desc { font-size: 13.5px; color: var(--dim); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips span {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.1em;
  color: var(--dim); border: 1px dashed rgba(156, 196, 255, 0.28);
  border-radius: 999px; padding: 5px 12px; white-space: nowrap;
}
.chips .price { color: var(--accent-3); border-style: solid; }
@media (max-width: 1000px) { .path-row { grid-template-columns: 1fr; gap: 10px; } }

.industry { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin-top: 7vh; }
/* industry cards — white glassmorphism: a brighter, business-like moment on the dark field */
.ind-card {
  border: 1px solid rgba(255, 255, 255, 0.55); border-radius: 16px;
  padding: clamp(24px, 3vw, 40px);
  background: linear-gradient(150deg, rgba(244, 248, 254, 0.94), rgba(226, 235, 249, 0.86));
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  box-shadow: 0 18px 50px rgba(2, 6, 16, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.8);
  color: #23324d;
}
.ind-card h4 { font-size: 19px; font-weight: 700; margin-bottom: 18px; color: #0b1e3f; }
.ind-card h4 span {
  display: block; font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.24em;
  text-transform: uppercase; color: #5a6f93; margin-top: 4px;
}
.ind-card li { display: flex; gap: 10px; align-items: baseline; padding: 8px 0; font-size: 13.5px; color: #44557a; border-top: 1px solid rgba(11, 30, 63, 0.08); }
.ind-card li:first-child { border-top: none; }
.ind-card li b { color: #0b1e3f; font-weight: 700; }
.ind-card li i { width: 5px; height: 5px; border-radius: 50%; background: var(--accent-2); flex: none; }
@media (max-width: 820px) { .industry { grid-template-columns: 1fr; } }

/* ---------- GUIDE ---------- */
.guide-grid { display: grid; grid-template-columns: clamp(230px, 26vw, 320px) 1fr; gap: clamp(26px, 5vw, 70px); margin-top: 7vh; align-items: start; }
.photo { position: relative; isolation: isolate; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); aspect-ratio: 1 / 1.06; background: linear-gradient(160deg, #0a1730, #060c1a); }
.photo img {
  width: 100%; height: 100%; object-fit: cover; object-position: 50% 28%; display: block;
  opacity: 0.86; filter: saturate(0.55) contrast(1.06) brightness(0.92);
  transition: opacity 0.6s var(--ease-out), filter 0.6s var(--ease-out);
}
.photo::before {
  content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    radial-gradient(120% 90% at 78% 12%, rgba(111, 168, 255, 0.14), transparent 55%),
    linear-gradient(165deg, rgba(11, 30, 63, 0.28), rgba(4, 6, 12, 0.52) 88%);
}
.photo::after {
  content: ''; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(160deg, #3c66d9, #0b1e3f);
  mix-blend-mode: color; opacity: 0.32;
  transition: opacity 0.6s var(--ease-out);
}
@media (hover: hover) {
  .photo:hover img { opacity: 1; filter: saturate(0.8) contrast(1.04) brightness(1); }
  .photo:hover::after { opacity: 0.16; }
}
.photo .pmeta {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 2;
  display: flex; justify-content: space-between;
  padding: 12px 16px;
  font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--accent-3);
  background: linear-gradient(transparent, rgba(4, 8, 18, 0.85));
}
.photo-ph {
  aspect-ratio: 4 / 5; display: grid; place-items: center;
  background: linear-gradient(160deg, #0a1730, #060c1a);
  color: var(--dim-2); font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.3em;
}
.gbody h3 { font-size: clamp(20px, 2.4vw, 28px); font-weight: 700; line-height: 1.6; margin-bottom: 18px; }
.gbody p { color: var(--dim); font-size: 14.5px; margin-bottom: 14px; }
.quote {
  border-left: 2px solid var(--accent-2); padding: 6px 0 6px 20px;
  color: var(--ink); font-size: 15px; margin: 24px 0; line-height: 2;
}
.credits { display: flex; flex-wrap: wrap; gap: 8px; margin: 20px 0 14px; }
.credits span {
  font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--dim); border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px;
}
.sig { font-family: var(--font-mono); font-size: 11px; color: var(--accent-3); letter-spacing: 0.08em; }
@media (max-width: 900px) { .guide-grid { grid-template-columns: 1fr; } .photo { max-width: 300px; } }

/* ---------- NUMBERS ---------- */
.num-row {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px;
  background: var(--line); border: 1px solid var(--line);
  margin-top: 7vh;
}
.num-cell { background: rgba(7, 12, 24, 0.72); padding: clamp(24px, 3vw, 44px); }
.num-cell .k { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.24em; text-transform: uppercase; color: var(--dim-2); display: block; }
.num-cell .big {
  display: block; font-family: var(--font-en); font-weight: 700;
  font-size: clamp(38px, 5vw, 68px); line-height: 1.1; color: var(--ink);
  margin: 14px 0 8px; font-variant-numeric: tabular-nums;
}
.num-cell .big sup { font-size: 0.3em; color: var(--accent-3); font-weight: 400; margin-left: 4px; }
.num-cell .lab { font-size: 11.5px; color: var(--dim); display: block; }
.note { margin-top: 18px; font-size: 11px; color: var(--dim-2); }
@media (max-width: 1000px) { .num-row { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .num-row { grid-template-columns: 1fr; } }

/* ---------- FAQ ---------- */
.faq-list { margin-top: 6vh; border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item summary {
  list-style: none; display: flex; align-items: baseline; gap: 18px;
  padding: 24px 4px; cursor: pointer; font-size: 15px; font-weight: 600;
  transition: color 0.25s;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary:hover { color: var(--accent-3); }
.faq-item .qno { font-family: var(--font-mono); font-size: 10px; color: var(--accent-2); flex: none; }
.faq-item .qmark { margin-left: auto; flex: none; position: relative; width: 12px; height: 12px; }
.faq-item .qmark::before, .faq-item .qmark::after {
  content: ''; position: absolute; background: var(--dim); transition: transform 0.3s;
}
.faq-item .qmark::before { left: 0; right: 0; top: 5px; height: 1.5px; }
.faq-item .qmark::after { top: 0; bottom: 0; left: 5px; width: 1.5px; }
.faq-item[open] .qmark::after { transform: scaleY(0); }
.faq-a { padding: 0 4px 26px 40px; color: var(--dim); font-size: 14px; max-width: 56em; }

/* ---------- NEWS ---------- */
.news-list { margin-top: 5vh; border-top: 1px solid var(--line); }
.news-list a {
  display: grid; grid-template-columns: 110px 90px 1fr auto; gap: 20px; align-items: baseline;
  padding: 22px 4px; border-bottom: 1px solid var(--line);
  transition: background 0.25s, padding-left 0.25s;
}
.news-list a:hover { background: rgba(12, 22, 44, 0.4); padding-left: 14px; }
.news-list .d { font-family: var(--font-mono); font-size: 11px; color: var(--dim-2); }
.news-list .t { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--accent-3); }
.news-list .ttl { font-size: 14px; }
.news-list .arr { color: var(--accent-2); }
@media (max-width: 700px) { .news-list a { grid-template-columns: 1fr auto; } .news-list .t { display: none; } }

/* ---------- CALL ---------- */
#call { position: relative; padding: 22vh 0 16vh; }
#call .head { text-align: center; margin-bottom: 8vh; }
#call .head .eyebrow::after { content: ''; width: 26px; height: 1px; background: var(--accent-2); }
.call-grid { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: clamp(26px, 5vw, 70px); align-items: start; }
.form .field { margin-bottom: 22px; }
.form label { display: block; font-size: 12px; color: var(--dim); margin-bottom: 8px; letter-spacing: 0.06em; }
.form label .req {
  font-size: 9px; color: var(--accent-3); border: 1px solid rgba(156, 196, 255, 0.35);
  border-radius: 4px; padding: 1px 6px; margin-left: 8px; vertical-align: 1px;
}
.form input, .form select, .form textarea {
  width: 100%; background: rgba(10, 18, 34, 0.6);
  border: 1px solid var(--line); border-radius: 10px;
  color: var(--ink); font-family: inherit; font-size: 14px;
  padding: 13px 16px; outline: none;
  transition: border-color 0.25s, box-shadow 0.25s;
}
.form input:focus, .form select:focus, .form textarea:focus {
  border-color: var(--accent-2); box-shadow: 0 0 0 3px rgba(60, 102, 217, 0.18);
}
.form .err-msg { display: none; font-size: 11px; color: #ff8f8f; margin-top: 6px; }
.form .field.error .err-msg { display: block; }
.form .field.error input, .form .field.error select { border-color: #b8524f; }
.submit {
  display: inline-flex; align-items: center; gap: 12px;
  background: var(--ink); color: #0a1526;
  font-weight: 700; font-size: 14px; font-family: inherit;
  border: none; border-radius: 999px; padding: 16px 30px; cursor: pointer;
  transition: background 0.25s, transform 0.25s;
}
.submit:hover { background: var(--accent-3); transform: scale(1.02); }
.form-status { margin-top: 14px; font-size: 13px; color: var(--accent-3); min-height: 1.6em; }
.call-meta { display: grid; gap: 0; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.call-meta span {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 15px 20px; font-size: 12px; color: var(--dim);
  border-bottom: 1px solid var(--line); background: rgba(7, 12, 24, 0.62);
}
.call-meta span:last-child { border-bottom: none; }
.call-meta b { color: var(--ink); font-size: 14px; }
.side p { margin-top: 20px; font-size: 13px; color: var(--dim); }
.side a { color: var(--accent-3); border-bottom: 1px solid rgba(156, 196, 255, 0.3); }
@media (max-width: 900px) { .call-grid { grid-template-columns: 1fr; } }

/* ---------- footer ---------- */
footer { position: relative; z-index: 10; border-top: 1px solid var(--line); background: rgba(4, 7, 15, 0.85); backdrop-filter: blur(10px); }
.foot-grid {
  display: grid; grid-template-columns: 1.4fr 0.8fr 1fr 0.9fr; gap: 40px;
  padding: 70px 0 40px;
}
.fbrand { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.fbrand img { width: 22px; }
.fbrand b { font-family: var(--font-en); letter-spacing: 0.3em; font-size: 13px; }
.fdesc { font-size: 12.5px; color: var(--dim); max-width: 30em; }
footer h5 {
  font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.28em; text-transform: uppercase;
  color: var(--dim-2); margin-bottom: 16px;
}
footer ul li { padding: 4px 0; }
footer ul a { font-size: 13px; color: var(--dim); transition: color 0.2s; }
footer ul a:hover { color: var(--accent-3); }
.foot-mega {
  font-family: var(--font-en); font-weight: 700;
  font-size: clamp(70px, 15.5vw, 230px); line-height: 0.95; letter-spacing: 0.01em;
  color: transparent; -webkit-text-stroke: 1px rgba(140, 175, 235, 0.16);
  text-align: center; user-select: none; padding: 30px 0 10px;
}
.foot-mega em { font-style: normal; color: var(--accent-2); -webkit-text-stroke: 0; }
.foot-bottom {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px;
  padding: 22px 0 30px;
  font-family: var(--font-mono); font-size: 10px; color: var(--dim-2); letter-spacing: 0.08em;
}
.foot-bottom a { color: var(--dim); }
@media (max-width: 900px) { .foot-grid { grid-template-columns: 1fr 1fr; } }

/* ---------- FDE — 私たちの流儀 ---------- */
.fde-list { margin-top: 7vh; border-top: 1px solid var(--line); }
.fde-row { display: grid; grid-template-columns: 96px 1fr; gap: 20px; align-items: start;
  padding: 30px 0; border-bottom: 1px solid var(--line); transition: background 0.3s; }
.fde-row:hover { background: rgba(12, 22, 44, 0.4); }
.fde-row .fno { font-family: var(--font-en); font-weight: 700; font-size: clamp(30px, 4vw, 52px);
  line-height: 1; color: transparent; -webkit-text-stroke: 1px rgba(140, 175, 235, 0.35); }
.fde-row .fbody h3 { font-size: clamp(17px, 2vw, 23px); font-weight: 700; line-height: 1.5; }
.fde-row .fbody p { font-size: 13.5px; color: var(--dim); margin-top: 8px; max-width: 42em; }
.fde-foot { margin-top: 28px; font-size: 14.5px; color: var(--ink); line-height: 1.9;
  border-left: 2px solid var(--accent-2); padding-left: 20px; }
@media (max-width: 700px) { .fde-row { grid-template-columns: 56px 1fr; gap: 12px; } }

/* guide extras */
.cred-note { font-size: 12px; color: var(--dim); margin: 12px 0 4px; }
.cred-note a { color: var(--accent-3); border-bottom: 1px solid rgba(156, 196, 255, 0.3); }
.tech-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 16px 0 10px; }
.tech-strip b { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--dim-2); }
.tech-strip span { font-family: var(--font-mono); font-size: 10px; color: var(--dim);
  border: 1px solid var(--line); border-radius: 999px; padding: 4px 11px; }

/* ---------- Fit — 向く / 向かない + 比較 ---------- */
.fit-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; margin-top: 7vh; }
.fit-col { border: 1px solid var(--line); border-radius: 14px; padding: clamp(24px, 3vw, 38px);
  background: rgba(7, 12, 24, 0.62); }
.fit-col h3 { display: flex; align-items: center; gap: 10px; font-size: 18px; font-weight: 700; margin-bottom: 14px; }
.fit-mark { font-family: var(--font-mono); }
.fit-yes .fit-mark { color: var(--accent-3); }
.fit-no .fit-mark { color: #ff8f8f; }
.fit-col li { padding: 9px 0; font-size: 14px; color: var(--dim); border-top: 1px solid var(--line); }
.fit-col li:first-child { border-top: none; }
.fit-col li b { color: var(--ink); font-weight: 600; }
.compare { margin-top: 22px; border: 1px solid var(--line); border-radius: 12px; overflow-x: auto; }
.cmp-row { display: grid; grid-template-columns: 0.8fr 1fr 1fr 1fr 1.1fr; min-width: 640px; }
.cmp-row > span { padding: 12px 14px; font-size: 12px; color: var(--dim); border-top: 1px solid var(--line); border-right: 1px solid var(--line); }
.cmp-row > span:last-child { border-right: none; }
.cmp-row:first-child > span { border-top: none; }
.cmp-head > span { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--dim-2); background: rgba(12, 22, 44, 0.5); }
.cmp-row > span:first-child { color: var(--dim-2); font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.1em; }
.cmp-us { color: var(--accent-3) !important; background: rgba(60, 102, 217, 0.1); font-weight: 600; }
.cmp-head .cmp-us { color: var(--accent-3) !important; }

/* ---------- Evidence band ---------- */
.evidence { margin-top: 5vh; border-top: 1px dashed var(--line); padding-top: 26px; }
.ev-label { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.3em; text-transform: uppercase; color: var(--dim-2); }
.ev-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 16px; }
.ev-cell b { display: block; font-family: var(--font-en); font-weight: 700; font-size: clamp(26px, 3vw, 38px); color: var(--ink); }
.ev-cell span { display: block; font-size: 12.5px; color: var(--dim); margin: 6px 0 8px; max-width: 28em; }
.ev-cell cite { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.1em; color: var(--accent-2); font-style: normal; }
@media (max-width: 820px) { .ev-grid { grid-template-columns: 1fr; gap: 16px; } }

/* CTA reassurance strip */
.reassure { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 20px; }
.reassure span { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.08em; color: var(--dim);
  border: 1px solid var(--line); border-radius: 999px; padding: 6px 13px; }

/* ============================================================
   LIGHT ZONES — white "paper" sheets that reveal over the dark
   WebGL field. Hero & Works stay black; everything else rides
   on these sheets (phasera.jp white base).
   ============================================================ */
.paper, footer.light {
  --ink: #0b1e3f;
  --dim: #45587c;
  --dim-2: #8291ad;
  --accent: #3c66d9;
  --accent-2: #3c66d9;
  --accent-3: #2b55c4;
  --line: rgba(11, 30, 63, 0.12);
  --pill-line: rgba(11, 30, 63, 0.16);
  color: var(--ink);
}
.paper {
  --slant: clamp(30px, 4.5vw, 72px);
  position: relative; z-index: 10;
  /* white glassmorphism: the particle field shimmers through */
  background: linear-gradient(165deg, rgba(249, 251, 255, 0.9), rgba(232, 239, 249, 0.82));
  backdrop-filter: blur(16px) saturate(1.25);
  -webkit-backdrop-filter: blur(16px) saturate(1.25);
  padding-top: var(--slant); padding-bottom: var(--slant);
  /* reveal: the sheet slides up as it enters */
  transform: translateY(64px);
  transition: transform 1.1s var(--ease-out);
  will-change: transform;
}
.paper.on { transform: none; }
/* sharp diagonal edges — alternating direction per sheet */
.paper-a { margin: 8vh 0; clip-path: polygon(0 var(--slant), 100% 0, 100% calc(100% - var(--slant)), 0 100%); }
.paper-b { margin: 2vh 0 6vh; clip-path: polygon(0 0, 100% var(--slant), 100% 100%, 0 calc(100% - var(--slant))); }
.paper-c { margin-top: 2vh; padding-bottom: 4vh; clip-path: polygon(0 var(--slant), 100% 0, 100% 100%, 0 100%); }
footer.light {
  background: rgba(235, 240, 249, 0.92);
  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  border-top: 1px solid var(--line);
}

/* --- component overrides where dark values were hardcoded --- */
.paper .outline-no { -webkit-text-stroke-color: rgba(11, 30, 63, 0.13); }
.paper .leak { background: #ffffff; backdrop-filter: none; box-shadow: 0 6px 26px rgba(11, 30, 63, 0.05); }
.paper .leak:hover { background: #f7faff; }
.paper .path-row:hover, .paper .fde-row:hover { background: rgba(60, 102, 217, 0.045); }
.paper .chips span { border-color: rgba(11, 30, 63, 0.25); }
.paper .fde-row .fno { -webkit-text-stroke-color: rgba(11, 30, 63, 0.32); }
.paper .ind-card { box-shadow: 0 14px 38px rgba(11, 30, 63, 0.12), inset 0 1px 0 #fff; border-color: rgba(11, 30, 63, 0.1); }
.paper .photo-ph { background: linear-gradient(160deg, #e7edf6, #d9e2f0); color: var(--dim-2); }
.paper .photo .pmeta { background: linear-gradient(transparent, rgba(246, 248, 252, 0.92)); }
.paper .num-cell, .paper .fit-col, .paper .call-meta span { background: #ffffff; }
.paper .num-row { box-shadow: 0 6px 26px rgba(11, 30, 63, 0.05); }
.paper .fit-no .fit-mark { color: #c9403a; }
.paper .cmp-head > span { background: rgba(11, 30, 63, 0.05); }
.paper .news-list a:hover { background: rgba(60, 102, 217, 0.045); }
.paper .form input, .paper .form select, .paper .form textarea { background: #ffffff; }
.paper .submit { color: #f2f5fa; }
.paper .submit:hover { background: var(--accent-2); color: #fff; }
footer.light .foot-mega { -webkit-text-stroke-color: rgba(11, 30, 63, 0.15); }
footer.light .foot-mega em { color: var(--accent-2); }

/* fixed chrome over light sheets: solid dark pills, no muddy translucency */
body.chrome-top-light .nav {
  background: rgba(8, 14, 28, 0.94);
  border-color: rgba(8, 14, 28, 0.9);
  box-shadow: 0 10px 34px rgba(11, 30, 63, 0.28);
}
body.chrome-top-light .nav::before { background: rgba(11, 30, 63, 0.25); }
body.chrome-bot-light .ask-pill,
body.chrome-bot-light .scroll-pill {
  background: rgba(8, 14, 28, 0.94);
  border-color: rgba(8, 14, 28, 0.9);
  box-shadow: 0 10px 34px rgba(11, 30, 63, 0.28);
}

@media (prefers-reduced-motion: reduce) { .paper { transform: none; } }

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  .rv { opacity: 1; transform: none; }
}
