/* coorde Inc. corporate site */

:root {
  --brand: #3299c8;
  --brand-600: #1f80b2;
  --brand-700: #145f87;
  --brand-50: #ecf6fb;
  --ai: #7c5cff;
  --ai-50: #f1edff;
  --cyan: #2fd4f0;
  --ink: #0b1220;
  --ink-2: #1d2939;
  --muted: #5d6b82;
  --line: #e4e8ef;
  --paper: #f5f7fa;
  --white: #fff;
  --navy: #070b16;
  --navy-2: #0e1526;
  --grad: linear-gradient(110deg, var(--brand) 0%, #4f7dff 45%, var(--ai) 100%);
  --max: 1200px;
  --radius: 22px;
  --font-sans: "Inter", "Noto Sans JP", -apple-system, BlinkMacSystemFont, "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--white);
  font-family: var(--font-sans);
  line-height: 1.8;
  letter-spacing: .02em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
h1, h2, h3 { font-feature-settings: "palt"; word-break: auto-phrase; }
p { word-break: auto-phrase; }

.container { width: min(var(--max), calc(100% - 48px)); margin-inline: auto; }

.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  padding: 10px 16px; border-radius: 10px; background: var(--ink); color: #fff;
}
.skip-link:focus { top: 12px; }

:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 6px; }

/* ---------- 共通パーツ ---------- */

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: .74rem; font-weight: 500;
  letter-spacing: .14em; text-transform: uppercase; color: var(--brand-600);
}
.eyebrow::before { content: ""; width: 22px; height: 1px; background: currentColor; }

.gradient-text {
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

.button {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 14px 22px; border-radius: 999px;
  background: var(--ink); color: #fff; font-weight: 700; font-size: .9rem;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}
.button:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(11, 18, 32, .18); }
.button .arrow { transition: transform .2s ease; }
.button:hover .arrow { transform: translate(2px, -2px); }

.button--brand { background: var(--grad); background-size: 160% 100%; background-position: 0 0; }
.button--brand:hover { background-position: 100% 0; box-shadow: 0 14px 36px rgba(79, 125, 255, .35); }

.button--ghost { background: transparent; color: var(--ink); border: 1px solid #d5dbe5; }
.button--ghost:hover { background: #fff; box-shadow: 0 10px 26px rgba(11, 18, 32, .08); }

.section { padding: 128px 0; position: relative; }

.section-head { display: flex; justify-content: space-between; align-items: end; gap: 40px; margin-bottom: 56px; }
.section-head h2,
.section-title {
  margin: 16px 0 0;
  font-size: clamp(2rem, 4.2vw, 3.4rem);
  line-height: 1.22; letter-spacing: -.02em; font-weight: 800;
}
.section-head p { max-width: 440px; margin: 0; color: var(--muted); }

.tag {
  display: inline-flex; align-items: center;
  padding: 4px 10px; border-radius: 999px;
  font-family: var(--font-mono); font-size: .7rem; letter-spacing: .04em;
  color: var(--brand-700); background: var(--brand-50);
}

.icon { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- ヘッダー ---------- */

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .94);
  backdrop-filter: saturate(180%) blur(18px); -webkit-backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease, background .3s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--line); background: rgba(255, 255, 255, .96); }

.nav { height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }

.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark { width: 38px; height: 38px; object-fit: contain; }
.brand-wordmark { width: 112px; height: auto; }

.nav-links { display: flex; align-items: center; gap: 30px; font-size: .86rem; font-weight: 600; }
.nav-links a:not(.button) { position: relative; color: var(--ink-2); transition: color .2s; }
.nav-links a:not(.button)::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -6px; height: 1.5px;
  background: var(--grad); transform: scaleX(0); transform-origin: left; transition: transform .25s ease;
}
.nav-links a:not(.button):hover { color: var(--ink); }
.nav-links a:not(.button):hover::after { transform: scaleX(1); }
.nav-links .nav-ai { display: inline-flex; align-items: center; gap: 6px; }
.nav-links .nav-ai::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--ai); box-shadow: 0 0 0 4px rgba(124, 92, 255, .15); }
.nav-links .button { padding: 11px 18px; font-size: .84rem; }

.menu-toggle {
  display: none; width: 44px; height: 44px; border: 1px solid var(--line); border-radius: 12px;
  background: #fff; cursor: pointer; place-items: center;
}
.menu-toggle span, .menu-toggle span::before, .menu-toggle span::after {
  display: block; width: 18px; height: 1.5px; background: var(--ink); position: relative; transition: transform .25s ease, background .25s ease;
}
.menu-toggle span::before, .menu-toggle span::after { content: ""; position: absolute; left: 0; }
.menu-toggle span::before { top: -6px; }
.menu-toggle span::after { top: 6px; }
.menu-toggle[aria-expanded="true"] span { background: transparent; }
.menu-toggle[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); }

/* ---------- ヒーロー（宇宙） ---------- */

.hero {
  position: relative; overflow: hidden; isolation: isolate;
  padding: 104px 0 112px; color: #fff;
  background: radial-gradient(ellipse 90% 70% at 70% 45%, #0d1224 0%, #05070f 55%, #020308 100%);
}

.hero-bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.space-canvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; transition: opacity 1.6s ease; }
.space-canvas.is-ready { opacity: 1; }
.hero::after {
  content: ""; position: absolute; inset: auto 0 0; height: 140px; z-index: -1; pointer-events: none;
  background: linear-gradient(to bottom, transparent, rgba(2, 3, 8, .9));
}

.hero-inner { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 40px; }

.hero-badge {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 6px 14px 6px 6px; border-radius: 999px;
  background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .14);
  font-size: .8rem; font-weight: 600; color: #dfe6f3;
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.hero-badge b {
  padding: 3px 10px; border-radius: 999px; color: #fff; background: var(--grad);
  font-family: var(--font-mono); font-size: .68rem; letter-spacing: .08em; font-weight: 500;
}

.hero h1 {
  margin: 28px 0 24px;
  font-size: clamp(2.7rem, 5.4vw, 4.8rem);
  line-height: 1.14; letter-spacing: -.035em; font-weight: 900;
  text-shadow: 0 10px 40px rgba(0, 0, 0, .5);
}
.hero h1 .gradient-text { background: linear-gradient(110deg, #7fd3f5 0%, #8ea2ff 50%, #b39bff 100%); -webkit-background-clip: text; background-clip: text; }
.hero-lead { max-width: 540px; margin: 0; color: #b9c3d6; font-size: 1.05rem; line-height: 2; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 38px; }
.hero .button--ghost { color: #fff; border-color: rgba(255, 255, 255, .25); background: rgba(255, 255, 255, .04); }
.hero .button--ghost:hover { background: rgba(255, 255, 255, .1); box-shadow: none; }

.hero-stats { display: flex; flex-wrap: wrap; margin: 52px 0 0; padding: 0; list-style: none; }
.hero-stats li { padding: 0 26px; border-left: 1px solid rgba(255, 255, 255, .14); }
.hero-stats li:first-child { padding-left: 0; border-left: 0; }
.hero-stats strong { display: block; font-size: 1.15rem; font-weight: 800; letter-spacing: -.01em; }
.hero-stats span { display: block; font-family: var(--font-mono); font-size: .68rem; letter-spacing: .1em; color: #8592ab; text-transform: uppercase; }

/* ヒーローのビジュアル（中央のブラックホールは canvas に描く） */
.hero-visual { position: relative; min-height: 580px; perspective: 1100px; }
.hero-scene {
  position: absolute; inset: 0; transform-style: preserve-3d;
  transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
}

.terminal {
  position: absolute; z-index: 3; right: 0; bottom: 0; width: min(310px, 64%);
  border-radius: 16px; overflow: hidden;
  background: rgba(8, 11, 22, .72); color: #d6deeb;
  box-shadow: 0 30px 70px rgba(0, 0, 0, .55); border: 1px solid rgba(255, 255, 255, .1);
  font-family: var(--font-mono); font-size: .74rem; line-height: 1.75;
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  transform: translateZ(90px);
}
.terminal-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; background: rgba(255, 255, 255, .04); border-bottom: 1px solid rgba(255, 255, 255, .06); }
.terminal-bar i { width: 9px; height: 9px; border-radius: 50%; background: #3a4458; }
.terminal-bar i:nth-child(1) { background: #ff6b6b; }
.terminal-bar i:nth-child(2) { background: #ffcf5c; }
.terminal-bar i:nth-child(3) { background: #3ddc97; }
.terminal-bar span { margin-left: 8px; color: #7d8aa3; font-size: .68rem; }
.terminal-body { margin: 0; padding: 14px 16px 16px; min-height: 148px; white-space: pre-wrap; }
.terminal-body .prompt { color: var(--cyan); }
.terminal-body .ok { color: #3ddc97; }
.terminal-body .next { color: #a996ff; }
.caret { display: inline-block; width: 7px; height: 1.05em; vertical-align: -2px; background: var(--cyan); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

.chip {
  position: absolute; z-index: 3;
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; border-radius: 14px;
  background: rgba(12, 16, 30, .55); border: 1px solid rgba(255, 255, 255, .12);
  box-shadow: 0 18px 44px rgba(0, 0, 0, .4);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  font-size: .8rem; font-weight: 700; color: #f2f5fb; white-space: nowrap;
}
.chip small { display: block; font-weight: 500; font-size: .68rem; color: #95a2bb; }
.chip-icon { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: rgba(50, 153, 200, .18); color: #7fd3f5; }
.chip-icon .icon { width: 17px; height: 17px; }
.chip--ai .chip-icon { background: rgba(124, 92, 255, .2); color: #c2b4ff; }
.chip--a { top: 6px; left: 0; transform: translateZ(60px); }
.chip--b { top: 6px; right: 0; transform: translateZ(40px); }
.chip--c { bottom: 196px; left: 0; transform: translateZ(70px); }

/* ---------- キーワードの流れる帯 ---------- */

.marquee { border-block: 1px solid rgba(255, 255, 255, .06); background: #020308; overflow: hidden; }
.marquee-track { display: flex; width: max-content; animation: marquee 38s linear infinite; }
.marquee ul { display: flex; gap: 0; margin: 0; padding: 0; list-style: none; }
.marquee li {
  display: flex; align-items: center; gap: 22px; padding: 20px 22px 20px 0;
  font-family: var(--font-mono); font-size: .8rem; letter-spacing: .08em; color: #7d89a0; white-space: nowrap;
}
.marquee li::after { content: "◆"; font-size: .5rem; color: #3b465c; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Mission ---------- */

.mission { background: var(--navy); color: #fff; overflow: hidden; }
.mission::after,
.contact-card .stars {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .55;
  background-image:
    radial-gradient(1px 1px at 12% 18%, #fff, transparent),
    radial-gradient(1px 1px at 28% 72%, #cfe3ff, transparent),
    radial-gradient(1.5px 1.5px at 46% 34%, #fff, transparent),
    radial-gradient(1px 1px at 63% 82%, #fff, transparent),
    radial-gradient(1px 1px at 78% 24%, #ffe9c9, transparent),
    radial-gradient(1.5px 1.5px at 88% 64%, #fff, transparent),
    radial-gradient(1px 1px at 6% 90%, #cfe3ff, transparent),
    radial-gradient(1px 1px at 54% 8%, #fff, transparent);
  background-size: 420px 420px;
}
.mission::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(600px 300px at 85% 10%, rgba(50, 153, 200, .25), transparent 70%),
    radial-gradient(500px 300px at 10% 100%, rgba(124, 92, 255, .2), transparent 70%);
}
.mission .eyebrow { color: #8fd0ec; }
.mission-inner { position: relative; display: grid; grid-template-columns: .65fr 1.35fr; gap: 64px; }
.mission-label { margin: 14px 0 0; color: #93a0b8; font-size: .9rem; }
.mission h2 { margin: 0 0 32px; font-size: clamp(2.1rem, 4.4vw, 3.9rem); line-height: 1.3; letter-spacing: -.02em; font-weight: 800; }
.mission h2 span { background: linear-gradient(110deg, #7cc8ea, #a996ff); -webkit-background-clip: text; background-clip: text; color: transparent; }
.mission p { margin: 0 0 22px; max-width: 700px; color: #b6c1d4; line-height: 2.1; }
.mission-sign { margin-top: 36px; display: flex; align-items: center; gap: 14px; color: #dfe6f1; font-size: .9rem; }
.mission-sign::before { content: ""; width: 34px; height: 1px; background: #55627a; }

/* ---------- Services（ベント） ---------- */

.services { background: var(--paper); }
.bento { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }

.card {
  position: relative; display: flex; flex-direction: column;
  padding: 30px; border-radius: var(--radius);
  background: #fff; border: 1px solid var(--line);
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 22px 50px rgba(11, 18, 32, .07); border-color: #cfd8e6; }
.card-top { display: flex; justify-content: space-between; align-items: start; margin-bottom: 30px; }
.card-num { font-family: var(--font-mono); font-size: .72rem; letter-spacing: .1em; color: #8692a6; }
.card-icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; background: var(--brand-50); color: var(--brand-600); }
.card h3 { margin: 0 0 12px; font-size: 1.28rem; letter-spacing: -.01em; }
.card p { margin: 0; color: var(--muted); font-size: .92rem; }
.card-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 26px; }

.card--ai {
  grid-row: span 2; color: #fff; border: 0; overflow: hidden; isolation: isolate;
  background: var(--navy-2);
}
.card--ai::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(420px 320px at 100% 0%, rgba(124, 92, 255, .55), transparent 70%),
    radial-gradient(380px 300px at 0% 100%, rgba(50, 153, 200, .5), transparent 70%);
}
.card--ai::after {
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: .5;
  background-image: radial-gradient(rgba(255, 255, 255, .18) 1px, transparent 1px);
  background-size: 18px 18px;
  -webkit-mask-image: linear-gradient(160deg, #000, transparent 70%); mask-image: linear-gradient(160deg, #000, transparent 70%);
}
.card--ai:hover { box-shadow: 0 26px 60px rgba(79, 125, 255, .3); }
.card--ai .card-num { color: #aab6cc; }
.card--ai .card-icon { background: rgba(255, 255, 255, .1); color: #fff; }
.card--ai h3 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); line-height: 1.3; margin-bottom: 16px; }
.card--ai p { color: #c3cde0; font-size: .96rem; }
.card--ai .tag { color: #e7ebff; background: rgba(255, 255, 255, .1); }
.card-new {
  display: inline-block; margin-bottom: 14px; padding: 3px 10px; border-radius: 999px;
  background: var(--grad); font-family: var(--font-mono); font-size: .66rem; letter-spacing: .1em;
}
.card-link { display: inline-flex; align-items: center; gap: 8px; margin-top: 28px; font-weight: 700; font-size: .88rem; }
.card-link:hover .arrow { transform: translate(2px, -2px); }
.card-link .arrow { transition: transform .2s ease; }

/* ---------- AI 開発 ---------- */

.ai { background: var(--navy); color: #fff; overflow: hidden; padding-bottom: 200px; }
.ai::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(700px 400px at 90% 0%, rgba(124, 92, 255, .28), transparent 70%),
    radial-gradient(600px 400px at 0% 60%, rgba(50, 153, 200, .2), transparent 70%);
}
.ai::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(255, 255, 255, .04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255, 255, 255, .04) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: linear-gradient(to bottom, #000, transparent 85%); mask-image: linear-gradient(to bottom, #000, transparent 85%);
}
.ai .container { position: relative; z-index: 1; }
.ai-floor {
  position: absolute; left: -50%; right: -50%; bottom: 0; height: 80%; pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(127, 211, 245, .38) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(169, 150, 255, .38) 1px, transparent 1px);
  background-size: 80px 80px;
  transform: perspective(520px) rotateX(68deg);
  transform-origin: center bottom;
  -webkit-mask-image: linear-gradient(to top, #000 0%, rgba(0, 0, 0, .5) 40%, transparent 85%);
  mask-image: linear-gradient(to top, #000 0%, rgba(0, 0, 0, .5) 40%, transparent 85%);
  animation: floor 6s linear infinite;
}
@keyframes floor { to { background-position: 0 80px; } }
.ai .eyebrow { color: #b6a6ff; }
.ai .section-head p { color: #aab6cc; }

/* 関係図（ナレッジグラフ） */
.graph-block { margin-bottom: 72px; }
.graph-intro { max-width: 720px; margin-bottom: 28px; }
.graph-intro h3 { margin: 12px 0 12px; font-size: clamp(1.4rem, 2.6vw, 1.9rem); line-height: 1.4; }
.graph-intro p { margin: 0; color: #aab6cc; font-size: .92rem; }

.graph-console {
  border-radius: 22px; overflow: hidden;
  background: linear-gradient(180deg, rgba(10, 14, 28, .92), rgba(6, 9, 18, .92));
  border: 1px solid rgba(255, 255, 255, .1);
  box-shadow: 0 40px 90px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 255, 255, .05);
}
.graph-bar { display: flex; align-items: center; gap: 14px; padding: 12px 18px; border-bottom: 1px solid rgba(255, 255, 255, .07); background: rgba(255, 255, 255, .03); }
.graph-bar-dots { display: flex; gap: 6px; }
.graph-bar-dots i { width: 9px; height: 9px; border-radius: 50%; background: #3a4458; }
.graph-query {
  flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-family: var(--font-mono); font-size: .78rem; color: #8fe3f7;
}
.graph-query::before { content: "neo4j$ "; color: #5d6b82; }
.graph-reset {
  flex: none; padding: 6px 12px; border-radius: 999px; cursor: pointer;
  background: rgba(143, 227, 247, .1); border: 1px solid rgba(143, 227, 247, .35); color: #bfefff;
  font-family: var(--font-mono); font-size: .7rem; letter-spacing: .04em;
  transition: background .2s ease;
}
.graph-reset:hover { background: rgba(143, 227, 247, .2); }
.graph-reset[hidden] { display: none; }

.graph-hint { display: none; margin: 0; padding: 8px 18px 0; font-family: var(--font-mono); font-size: .7rem; color: #7d8aa3; text-align: center; }
.graph-body { display: grid; grid-template-columns: 1fr 270px; }
.graph-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.graph-canvas {
  position: relative; min-width: 760px; padding: 4px 0;
  background-image: radial-gradient(rgba(255, 255, 255, .07) 1px, transparent 1px);
  background-size: 22px 22px;
}
.graph-svg { display: block; width: 100%; height: auto; overflow: hidden; }

.graph-arrow { fill: rgba(170, 182, 204, .55); }
.edge-line { fill: none; stroke: rgba(170, 182, 204, .28); stroke-width: 1.4; transition: stroke .3s ease, opacity .3s ease; }
.edge-flow {
  fill: none; stroke: rgba(143, 227, 247, .55); stroke-width: 2; stroke-linecap: round;
  stroke-dasharray: 2 16; animation: graph-flow 1.8s linear infinite; opacity: .6;
}
@keyframes graph-flow { to { stroke-dashoffset: -18; } }
.edge-label {
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .04em; fill: #7d8aa3;
  paint-order: stroke; stroke: #080c18; stroke-width: 4px; stroke-linejoin: round;
  transition: fill .3s ease, opacity .3s ease;
}

.graph-node { cursor: pointer; outline: none; transition: opacity .3s ease; }
.node-body { animation: node-float 6s ease-in-out infinite; animation-delay: var(--float-delay, 0s); transition: transform .3s ease; }
@keyframes node-float { 50% { transform: translateY(-4px); } }
.node-halo { fill: var(--node-color); opacity: .08; transition: opacity .3s ease; }
.node-core { fill: var(--node-color); opacity: .9; }
.node-inner { fill: #0a0f1d; stroke: rgba(255, 255, 255, .25); stroke-width: 1; }
.node-tag { font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; fill: var(--node-color); font-weight: 500; }
.node-name {
  font-size: 16.5px; font-weight: 700; fill: #e8edf6;
  paint-order: stroke; stroke: #080c18; stroke-width: 5px; stroke-linejoin: round;
}
.graph-node:hover .node-halo,
.graph-node:focus-visible .node-halo,
.graph-node.is-active .node-halo { opacity: .28; }
.graph-node:focus-visible .node-inner { stroke: #fff; stroke-width: 2; }

/* 選択したノードとつながりだけを強調 */
.graph-canvas.is-focused .graph-node { opacity: .2; }
.graph-canvas.is-focused .graph-node.is-active,
.graph-canvas.is-focused .graph-node.is-near { opacity: 1; }
.graph-canvas.is-focused .graph-node.is-active .node-body { transform: scale(1.12); }
.graph-canvas.is-focused .graph-edge { opacity: .12; }
.graph-canvas.is-focused .graph-edge.is-active { opacity: 1; }
.graph-edge.is-active .edge-line { stroke: rgba(143, 227, 247, .8); stroke-width: 1.8; }
.graph-edge.is-active .edge-flow { stroke: #fff; opacity: 1; }
.graph-edge.is-active .edge-label { fill: #e8f8ff; }

.graph-detail { padding: 26px 24px; border-left: 1px solid rgba(255, 255, 255, .07); background: rgba(255, 255, 255, .02); min-height: 100%; }
.graph-detail h4 { margin: 8px 0 10px; font-size: 1.15rem; line-height: 1.4; }
.graph-detail p { margin: 0; color: #aab6cc; font-size: .86rem; }
.graph-detail-label { display: flex; align-items: center; gap: 8px; font-family: var(--font-mono); font-size: .72rem !important; letter-spacing: .08em; color: #8b98b0 !important; }
.graph-relations { margin: 18px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.graph-relations code {
  display: block; padding: 8px 10px; border-radius: 8px;
  background: rgba(255, 255, 255, .04); border: 1px solid rgba(255, 255, 255, .07);
  font-family: var(--font-mono); font-size: .72rem; color: #c9d4e6; word-break: break-all;
}
.legend-dot { flex: none; width: 9px; height: 9px; border-radius: 50%; background: var(--node-color); box-shadow: 0 0 10px var(--node-color); }

.graph-legend { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 0; padding: 14px 18px; border-top: 1px solid rgba(255, 255, 255, .07); list-style: none; }
.graph-legend li { display: flex; align-items: center; gap: 8px; font-size: .76rem; color: #8b98b0; }
.graph-legend code { font-family: var(--font-mono); color: #dfe6f1; }

.ai-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.ai-card {
  padding: 26px; border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .02));
  border: 1px solid rgba(255, 255, 255, .09);
  transition: border-color .3s ease, transform .3s ease, background .3s ease;
}
.ai-card:hover { transform: translateY(-4px); border-color: rgba(169, 150, 255, .5); background: linear-gradient(180deg, rgba(124, 92, 255, .14), rgba(255, 255, 255, .02)); }
.ai-card .card-icon { background: rgba(124, 92, 255, .16); color: #c7bbff; margin-bottom: 22px; }
.ai-card h3 { margin: 0 0 10px; font-size: 1.05rem; line-height: 1.5; }
.ai-card p { margin: 0; color: #aab6cc; font-size: .86rem; }

.ai-driven {
  display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center;
  margin-top: 16px; padding: 36px 40px; border-radius: 22px;
  background: linear-gradient(110deg, rgba(50, 153, 200, .16), rgba(124, 92, 255, .2));
  border: 1px solid rgba(255, 255, 255, .1);
}
.ai-driven h3 { margin: 10px 0 12px; font-size: clamp(1.35rem, 2.4vw, 1.8rem); line-height: 1.4; }
.ai-driven p { margin: 0; color: #c3cde0; font-size: .92rem; }
.ai-driven ul { display: grid; gap: 8px; margin: 22px 0 0; padding: 0; list-style: none; }
.ai-driven li { display: flex; align-items: center; gap: 10px; font-size: .88rem; color: #dfe6f1; }
.ai-driven li::before { content: "→"; font-family: var(--font-mono); color: var(--cyan); }

.tools { display: grid; gap: 12px; }
.tool {
  padding: 22px 24px; border-radius: 16px;
  background: rgba(7, 11, 22, .55); border: 1px solid rgba(255, 255, 255, .1);
  transition: border-color .3s ease, transform .3s ease;
}
.tool:hover { transform: translateY(-3px); border-color: rgba(47, 212, 240, .45); }
.tool-head { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.tool-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: rgba(47, 212, 240, .12); color: var(--cyan); }
.tool h4 { margin: 0; font-size: 1.1rem; letter-spacing: -.01em; line-height: 1.3; }
.tool-head span { font-family: var(--font-mono); font-size: .7rem; letter-spacing: .06em; color: #8b98b0; }
.tool p { margin: 0; color: #b6c1d4; font-size: .86rem; }

.ai-flow { margin-top: 72px; }
.ai-flow-title { margin: 0 0 26px; font-family: var(--font-mono); font-size: .76rem; letter-spacing: .14em; text-transform: uppercase; color: #8b98b0; font-weight: 500; }
.flow { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin: 0; padding: 0; list-style: none; counter-reset: step; position: relative; }
.flow::before {
  content: ""; position: absolute; left: 0; right: 0; top: 15px; height: 1px;
  background: linear-gradient(90deg, var(--brand), var(--ai));
}
.flow li { position: relative; padding: 0 24px 0 0; counter-increment: step; }
.flow li::before {
  content: counter(step, decimal-leading-zero); display: grid; place-items: center;
  width: 32px; height: 32px; margin-bottom: 20px; border-radius: 50%;
  background: var(--navy); border: 1px solid #5a6a8a;
  font-family: var(--font-mono); font-size: .68rem; color: #dfe6f1; position: relative;
}
.flow h3 { margin: 0 0 6px; font-size: .98rem; }
.flow p { margin: 0; color: #9aa7bf; font-size: .84rem; }

.ai-note { margin: 56px 0 0; padding-top: 28px; border-top: 1px solid rgba(255, 255, 255, .1); display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.ai-note div { display: flex; gap: 14px; }
.ai-note .icon { flex: none; color: var(--cyan); margin-top: 3px; }
.ai-note p { margin: 0; }
.ai-note strong { display: block; font-size: .92rem; margin-bottom: 4px; }
.ai-note span { color: #9aa7bf; font-size: .84rem; }

/* ---------- Approach ---------- */

.approach-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 80px; }
.approach-intro { position: sticky; top: 120px; align-self: start; }
.approach-intro p { color: var(--muted); max-width: 400px; margin-top: 22px; }
.steps { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.steps li { display: grid; grid-template-columns: 64px 1fr; gap: 20px; padding: 28px 0; border-bottom: 1px solid var(--line); }
.steps .num { font-family: var(--font-mono); font-size: .8rem; color: var(--brand-600); padding-top: 4px; }
.steps h3 { margin: 0 0 6px; font-size: 1.1rem; }
.steps p { margin: 0; color: var(--muted); font-size: .9rem; }

/* ---------- Experience ---------- */

.experience { background: var(--paper); }
.cases { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.case { grid-column: span 2; padding: 28px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); display: flex; flex-direction: column; transition: transform .3s ease, box-shadow .3s ease; }
.case:nth-child(4), .case:nth-child(5) { grid-column: span 3; }
.case:hover { transform: translateY(-4px); box-shadow: 0 22px 50px rgba(11, 18, 32, .07); }
.case-media {
  margin: -12px -12px 24px; border-radius: 16px; overflow: hidden; aspect-ratio: 16 / 10;
  background: #070b16; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06);
}
.case-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.case:hover .case-media img { transform: scale(1.05); }
.case-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 22px; }
.case-num { font-family: var(--font-mono); font-size: .72rem; color: #8692a6; letter-spacing: .1em; }
.case h3 { margin: 0 0 12px; font-size: 1.15rem; }
.case p { margin: 0; color: var(--muted); font-size: .9rem; }
.case .card-tags { padding-top: 22px; }


/* ---------- Company ---------- */

.company-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 72px; align-items: start; }
.company-logo {
  margin-top: 36px; padding: 40px; border-radius: var(--radius);
  background: linear-gradient(180deg, #fff, var(--paper)); border: 1px solid var(--line);
  display: grid; place-items: center;
}
.company-logo img { width: 150px; }
.company-table { margin: 0; border-top: 1px solid var(--line); }
.company-row { display: grid; grid-template-columns: 150px 1fr; gap: 24px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.company-row dt { color: var(--muted); font-size: .88rem; }
.company-row dd { margin: 0; font-weight: 600; }
.company-row dd small { display: block; font-weight: 400; color: var(--muted); font-size: .84rem; }

/* ---------- Contact ---------- */

.contact { padding: 0 0 128px; }
.contact-card {
  position: relative; overflow: hidden; isolation: isolate;
  padding: 72px 64px; border-radius: 32px; color: #fff;
  background: var(--navy-2);
  display: flex; justify-content: space-between; align-items: center; gap: 40px;
}
.contact-card::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(520px 360px at 100% 0%, rgba(124, 92, 255, .6), transparent 70%),
    radial-gradient(520px 360px at 0% 100%, rgba(50, 153, 200, .6), transparent 70%);
}
.contact-card::after {
  content: ""; position: absolute; width: 520px; height: 520px; right: -120px; bottom: -300px; z-index: -1;
  border: 1px solid rgba(255, 255, 255, .16); border-radius: 50%;
  box-shadow: 0 0 0 60px rgba(255, 255, 255, .03), 0 0 0 120px rgba(255, 255, 255, .02);
}
.contact .eyebrow { color: #c9d8ff; }
.contact h2 { margin: 16px 0 14px; font-size: clamp(2rem, 4.4vw, 3.6rem); line-height: 1.2; letter-spacing: -.02em; }
.contact p { margin: 0; color: #d3dcef; max-width: 520px; }
.contact .button { background: #fff; color: var(--ink); padding: 18px 26px; font-size: .95rem; white-space: nowrap; }

/* ---------- フッター ---------- */

.site-footer { border-top: 1px solid var(--line); padding: 44px 0; background: #fff; }
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.footer-brand { display: flex; align-items: center; gap: 18px; }
.footer-brand .brand { flex: none; }
.footer-brand span { font-family: var(--font-mono); font-size: .72rem; letter-spacing: .08em; color: var(--muted); }
.footer-links { display: flex; flex-wrap: wrap; gap: 24px; font-size: .84rem; font-weight: 600; color: var(--ink-2); }
.footer-links a:hover { color: var(--brand-600); }
.copyright { font-size: .76rem; color: var(--muted); }
.trademark { flex-basis: 100%; margin: 4px 0 0; padding-top: 18px; border-top: 1px solid var(--line); font-size: .7rem; color: #8692a6; }

/* ---------- カードの 3D 傾き ---------- */

[data-tilt] { transform-style: preserve-3d; }
[data-tilt].is-tilting {
  transform: perspective(900px) rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg)) translateY(-4px);
  transition: transform .08s linear, box-shadow .3s ease, border-color .3s ease;
}
[data-tilt]::before { pointer-events: none; }
[data-tilt] > * { position: relative; z-index: 1; }
.card[data-tilt]:not(.card--ai)::before,
.case[data-tilt]::before,
.ai-card[data-tilt]::before,
.tool[data-tilt]::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; opacity: 0; transition: opacity .3s ease;
  background: radial-gradient(420px circle at var(--glare-x, 50%) var(--glare-y, 50%), rgba(50, 153, 200, .12), transparent 45%);
}
.ai-card[data-tilt]::before,
.tool[data-tilt]::before { background: radial-gradient(380px circle at var(--glare-x, 50%) var(--glare-y, 50%), rgba(169, 150, 255, .18), transparent 45%); }
[data-tilt].is-tilting::before { opacity: 1; }
.case, .ai-card, .tool { position: relative; }

/* ---------- 表示アニメーション ---------- */

.js .reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s cubic-bezier(.2, .7, .2, 1), transform .8s cubic-bezier(.2, .7, .2, 1); transition-delay: var(--delay, 0s); }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---------- レスポンシブ ---------- */

@media (max-width: 1080px) {
  .ai-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 960px) {
  .graph-body { grid-template-columns: 1fr; }
  .graph-detail { border-left: 0; border-top: 1px solid rgba(255, 255, 255, .07); min-height: 0; }
  .section { padding: 96px 0; }
  .hero { padding: 64px 0 72px; }
  .hero-inner { grid-template-columns: 1fr; gap: 8px; }
  .hero-visual { min-height: 540px; max-width: 560px; width: 100%; margin-inline: auto; }
  .section-head { flex-direction: column; align-items: start; gap: 18px; }
  .mission-inner, .approach-grid, .company-grid, .ai-driven { grid-template-columns: 1fr; gap: 32px; }
  .approach-intro { position: static; }
  .bento { grid-template-columns: repeat(2, 1fr); }
  .card--ai { grid-column: span 2; grid-row: auto; }
  .cases { grid-template-columns: repeat(2, 1fr); }
  .case, .case:nth-child(4), .case:nth-child(5) { grid-column: span 1; }
  .case:nth-child(5) { grid-column: span 2; }
  .flow { grid-template-columns: repeat(2, 1fr); row-gap: 36px; }
  .flow::before { display: none; }
  .ai-note { grid-template-columns: 1fr; gap: 20px; }
  .contact-card { flex-direction: column; align-items: flex-start; padding: 56px 40px; }
}

@media (max-width: 760px) {
  .menu-toggle { display: grid; }
  .nav-links {
    position: absolute; top: 76px; left: 0; right: 0;
    display: none; flex-direction: column; align-items: stretch; gap: 4px;
    padding: 12px 24px 24px; background: #fff; border-bottom: 1px solid var(--line);
    box-shadow: 0 20px 40px rgba(11, 18, 32, .08);
  }
  .nav-links.is-open { display: flex; }
  .nav-links a:not(.button) { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .nav-links a:not(.button)::after { display: none; }
  .nav-links .button { justify-content: center; margin-top: 12px; }
}

@media (max-width: 640px) {
  .container { width: calc(100% - 32px); }
  .nav { height: 68px; }
  .nav-links { top: 68px; padding-inline: 16px; }
  .brand-mark { width: 32px; height: 32px; }
  .brand-wordmark { width: 96px; }
  .section { padding: 76px 0; }
  .hero { padding: 44px 0 56px; }
  .hero h1 { font-size: clamp(2.3rem, 10.5vw, 3rem); }
  .hero-lead { font-size: .96rem; }
  .hero-actions .button { flex: 1 1 100%; justify-content: center; }
  .hero-stats { display: grid; grid-template-columns: auto auto auto; margin-top: 40px; }
  .hero-stats li { padding: 0 12px; }
  .hero-stats strong { font-size: .98rem; }
  .hero-stats span { font-size: .6rem; letter-spacing: .06em; }
  .hero-visual { min-height: 460px; margin-top: 32px; }
  .chip { padding: 8px 11px; font-size: .74rem; }
  .chip-icon { width: 26px; height: 26px; }
  .chip--a { top: 4px; }
  .chip--b, .chip--c { display: none; }
  .terminal { right: 0; bottom: 0; width: 88%; font-size: .68rem; }
  .terminal-body { min-height: 128px; }
  .bento, .cases, .ai-grid { grid-template-columns: 1fr; }
  .card--ai, .case:nth-child(5) { grid-column: auto; }
  .flow { grid-template-columns: 1fr; }
  .ai-driven { padding: 28px 22px; }
  .company-row { grid-template-columns: 96px 1fr; gap: 14px; font-size: .9rem; }
  .contact { padding-bottom: 76px; }
  .contact-card { padding: 44px 24px; border-radius: 24px; }
  .contact .button { width: 100%; justify-content: center; white-space: normal; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
  .footer-brand { flex-direction: column; align-items: flex-start; gap: 10px; }
  .graph-hint { display: block; }
}
