/* ================================================================
   shinta.tech — engineered premium
   ================================================================ */

:root {
  --bg: #050507;
  --bg-soft: #0a0a10;
  --panel: rgba(255, 255, 255, 0.025);
  --panel-hover: rgba(255, 255, 255, 0.045);
  --border: rgba(255, 255, 255, 0.09);
  --border-strong: rgba(255, 255, 255, 0.18);
  --text: #f2f2f5;
  --text-dim: #a3a3ae;
  --text-faint: #85858f;
  --accent: #a3e635;
  --accent-dim: rgba(163, 230, 53, 0.35);
  --accent-faint: rgba(163, 230, 53, 0.08);
  --linkedin: #4c9eea;
  --font-display: "Space Grotesk", "Inter", system-ui, sans-serif;
  --font-body: "Inter", "Hiragino Sans", "Yu Gothic", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", "SFMono-Regular", Menlo, monospace;
  --container: 1140px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.mono { font-family: var(--font-mono); }

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

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

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--accent);
  color: #050507;
  padding: 0.6rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
}
.skip-link:focus { left: 1rem; top: 1rem; color: #050507; }

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 24px;
}
.container.narrow { max-width: 820px; }

/* ---------------- header ---------------- */

.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 10;
  padding-block: 16px;
  background: rgba(5, 5, 7, 0.55);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.wordmark {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.18em;
  text-decoration: none;
  color: var(--text);
}
.header-right {
  display: flex;
  align-items: center;
  gap: 1.1rem;
}

.lang-toggle {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  color: var(--text-faint);
  display: flex;
  align-items: center;
  gap: 0.45rem;
}
.lang-toggle a {
  color: var(--text-dim);
  text-decoration: none;
}
.lang-toggle a:hover { color: var(--accent); }
.lang-toggle .current { color: var(--accent); }

.site-nav {
  display: flex;
  gap: 1.4rem;
}
.site-nav a {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.15s ease;
}
.site-nav a:hover { color: var(--text); }
.site-nav a.active { color: var(--accent); }

.header-cta {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  text-decoration: none;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.5rem 1rem;
  transition: border-color 0.2s ease, color 0.2s ease;
}
.header-cta:hover { border-color: var(--accent-dim); color: var(--accent); }

/* ---------------- hero ---------------- */

.hero {
  position: relative;
  min-height: 94vh;
  display: flex;
  align-items: center;
  overflow: hidden;
  isolation: isolate;
}

.hero-scene {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-scene canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1.6s ease;
}
.hero.is-live .hero-scene canvas { opacity: 1; }

.hero-static {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  transition: opacity 1.2s ease;
}
.hero.is-live .hero-static { opacity: 0; }
.hs-edges path { stroke: rgba(255, 255, 255, 0.07); stroke-width: 1; fill: none; }
.hs-nodes circle { fill: rgba(255, 255, 255, 0.35); }
.hs-accent circle { fill: var(--accent); }
.hs-accent .halo { fill: var(--accent); opacity: 0.12; }

.hero-shade {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(ellipse 90% 70% at 38% 45%, rgba(5, 5, 7, 0.86) 0%, rgba(5, 5, 7, 0.55) 55%, rgba(5, 5, 7, 0.25) 100%),
    linear-gradient(to bottom, rgba(5, 5, 7, 0.6) 0%, rgba(5, 5, 7, 0) 30%, rgba(5, 5, 7, 0) 60%, var(--bg) 100%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  padding-block: 140px 80px;
}

.hero-label {
  font-size: 0.75rem;
  letter-spacing: 0.16em;
  color: var(--accent);
  margin-bottom: 1.5rem;
}

h1 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.5rem, 5.6vw, 4.4rem);
  line-height: 1.06;
  letter-spacing: -0.02em;
  max-width: 15ch;
  margin-bottom: 1.5rem;
}

.hero-sub {
  color: var(--text-dim);
  font-size: 1.125rem;
  max-width: 58ch;
  margin-bottom: 2.25rem;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-bottom: 3.5rem;
}

.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  padding: 0.85rem 1.6rem;
  border-radius: 6px;
  transition: transform 0.15s ease, box-shadow 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}
.btn-primary {
  background: var(--accent);
  color: #0a0f02;
  border: 1px solid var(--accent);
}
.btn-primary:hover {
  color: #0a0f02;
  transform: translateY(-1px);
  box-shadow: 0 8px 30px rgba(163, 230, 53, 0.25);
}
.btn-ghost {
  color: var(--text);
  border: 1px solid var(--border-strong);
  background: rgba(255, 255, 255, 0.02);
}
.btn-ghost:hover {
  color: var(--text);
  border-color: var(--accent-dim);
  transform: translateY(-1px);
}
.btn-lg { padding: 1rem 2.2rem; font-size: 1.05rem; }

.credential-strip {
  font-size: 0.76rem;
  letter-spacing: 0.05em;
  color: var(--text-dim);
  border-top: 1px solid var(--border);
  padding-top: 1.1rem;
  max-width: 720px;
}
.credential-strip .sep { color: var(--accent); margin-inline: 0.7em; }

/* ---------------- sections ---------------- */

.section {
  position: relative;
  padding-block: 110px;
  scroll-margin-top: 56px; /* keep anchored headings clear of the fixed nav */
}
.section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(1140px, calc(100% - 48px));
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-dim) 30%, var(--accent-dim) 70%, transparent);
  box-shadow: 0 0 12px rgba(163, 230, 53, 0.25);
  opacity: 0.5;
}

.section-label {
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: var(--accent);
  margin-bottom: 1rem;
}

h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
  line-height: 1.15;
  letter-spacing: -0.015em;
  margin-bottom: 1.25rem;
  max-width: 24ch;
}

.section-intro {
  color: var(--text-dim);
  max-width: 62ch;
  margin-bottom: 3rem;
}

h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  line-height: 1.3;
  margin-bottom: 0.75rem;
}

/* ---------------- cards ---------------- */

.card-grid {
  display: grid;
  gap: 1.25rem;
}
.card-grid.three { grid-template-columns: repeat(3, 1fr); }

.card {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.75rem;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.25s ease, background-color 0.2s ease;
  background-image: linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 40%);
}
.card:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  background-color: var(--panel-hover);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.55), 0 1px 0 rgba(255, 255, 255, 0.06) inset;
}
.card p { color: var(--text-dim); font-size: 0.95rem; }
.card h3 { color: var(--text); }

.closer {
  margin-top: 3rem;
  font-size: 1.15rem;
  color: var(--text-dim);
  max-width: 60ch;
}
.closer strong { color: var(--accent); font-weight: 600; }

/* ---------------- proof of work ---------------- */

.build-list {
  display: grid;
  gap: 1.25rem;
  margin-bottom: 4.5rem;
}

.build-card { padding: 2rem; }
.build-tag {
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  color: var(--accent);
  margin-bottom: 0.6rem;
}
.build-rows { display: grid; gap: 0.9rem; margin-block: 1rem 1.4rem; }
.build-rows dt {
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  color: var(--text-faint);
  margin-bottom: 0.2rem;
}
.build-rows dd { color: var(--text-dim); font-size: 0.95rem; max-width: 75ch; }

.chips {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}
.chip {
  font-size: 0.74rem;
  letter-spacing: 0.02em;
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.38rem 0.85rem;
  color: var(--text-dim);
}
.chip a { color: var(--text); text-decoration: none; }
.chip a:hover { color: var(--accent); text-decoration: underline; }
.chip-metric {
  border-color: var(--accent-dim);
  color: var(--accent);
  background: var(--accent-faint);
}

.stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding-block: 2.5rem;
}
.stat-value {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.1rem, 3.6vw, 2.9rem);
  line-height: 1;
  color: var(--accent);
  margin-bottom: 0.7rem;
  font-variant-numeric: tabular-nums;
}
.stat-label {
  font-size: 0.72rem;
  line-height: 1.55;
  letter-spacing: 0.03em;
  color: var(--text-faint);
  max-width: 24ch;
}

.footnote {
  margin-top: 1.75rem;
  font-size: 0.86rem;
  color: var(--text-faint);
  max-width: 75ch;
}

/* ---------------- what I build ---------------- */

.bhe-diagram-wrap { margin-bottom: 3rem; }
.bhe-diagram {
  display: block;
  width: 100%;
  max-width: 760px;
  height: auto;
  margin-inline: auto;
}
.bhe-diagram text {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  fill: var(--text-dim);
}
.bhe-diagram .bhe-title { fill: var(--accent); font-size: 11px; }
.bhe-boundary {
  fill: var(--accent-faint);
  stroke: var(--accent-dim);
  stroke-width: 1;
  stroke-dasharray: 5 5;
}
.bhe-mod { fill: rgba(255, 255, 255, 0.03); stroke: var(--border-strong); stroke-width: 1; }
.bhe-io { fill: rgba(255, 255, 255, 0.02); stroke: var(--border); stroke-width: 1; }
.bhe-flow { stroke: var(--accent-dim); stroke-width: 1; }
.bhe-arrow { fill: var(--accent-dim); }

.module-card .price {
  margin-top: 1.1rem;
  font-size: 0.76rem;
  letter-spacing: 0.04em;
  color: var(--accent);
}

.retainer {
  margin-top: 2.25rem;
  color: var(--text-dim);
  font-size: 0.98rem;
}
.retainer-tag {
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  color: var(--accent);
  border: 1px solid var(--accent-dim);
  border-radius: 999px;
  padding: 0.25rem 0.7rem;
  margin-right: 0.75rem;
  vertical-align: 1px;
}

.rule-callout {
  margin-top: 2rem;
  border: 1px solid var(--border);
  border-left: 2px solid var(--accent);
  border-radius: 0 8px 8px 0;
  background: var(--panel);
  padding: 1.4rem 1.75rem;
  max-width: 720px;
}
.rule-callout p { color: var(--text); font-size: 1rem; }

/* ---------------- process ---------------- */

.process-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  counter-reset: step;
}
.process-step {
  border-top: 1px solid var(--border);
  padding-top: 1.4rem;
  position: relative;
}
.process-step::before {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: 44px;
  height: 1px;
  background: var(--accent);
}
.step-num {
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  color: var(--accent);
  margin-bottom: 0.8rem;
}
.process-step h3 { font-size: 1.1rem; }
.step-meta {
  font-size: 0.68rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  color: var(--text-faint);
  white-space: nowrap;
}
.process-step p:last-child { color: var(--text-dim); font-size: 0.92rem; }

/* ---------------- why me ---------------- */

.why-body { color: var(--text-dim); font-size: 1.05rem; margin-bottom: 2rem; }

.jp-line {
  border-left: 2px solid var(--accent);
  padding-left: 1.25rem;
  color: var(--text);
  font-size: 0.98rem;
}

/* ---------------- faq ---------------- */

.faq-list { border-top: 1px solid var(--border); }

.faq-list details { border-bottom: 1px solid var(--border); }

.faq-list summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1.5rem;
  padding-block: 1.3rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.08rem;
  transition: color 0.15s ease;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary:hover { color: var(--accent); }

.faq-marker {
  font-family: var(--font-mono);
  color: var(--accent);
  flex-shrink: 0;
  transition: transform 0.2s ease;
}
.faq-list details[open] .faq-marker { transform: rotate(45deg); }

.faq-list details p {
  color: var(--text-dim);
  padding-bottom: 1.5rem;
  max-width: 68ch;
}

/* ---------------- cta + footer ---------------- */

.cta-section {
  padding-block: 140px;
  background:
    radial-gradient(ellipse 60% 55% at 50% 60%, var(--accent-faint), transparent 70%),
    var(--bg);
}
.cta-inner { text-align: center; }
.cta-inner h2 { margin-inline: auto; max-width: 22ch; }
.cta-body {
  color: var(--text-dim);
  max-width: 56ch;
  margin: 0 auto 2.5rem;
}
.cta-secondary {
  margin-top: 2.25rem;
  font-size: 0.92rem;
  color: var(--text-faint);
}

.linkedin-link { color: var(--linkedin); }
.linkedin-link:hover { color: #7cbbf5; }

.site-footer {
  border-top: 1px solid var(--border);
  padding-block: 2.25rem;
}
.site-footer p {
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  color: var(--text-faint);
  line-height: 2;
}
.site-footer a { color: var(--text-dim); }
.site-footer a:hover { color: var(--accent); }
.site-footer a.linkedin-link { color: var(--linkedin); }
.site-footer a.linkedin-link:hover { color: #7cbbf5; }

/* ---------------- japanese page ---------------- */

html[lang="ja"] {
  --font-display: "Space Grotesk", "Noto Sans JP", "Hiragino Sans", "Yu Gothic", sans-serif;
  --font-body: "Inter", "Noto Sans JP", "Hiragino Sans", "Yu Gothic", sans-serif;
}
html[lang="ja"] body { line-height: 1.85; }
html[lang="ja"] h1 {
  max-width: 24ch;
  letter-spacing: 0;
  line-height: 1.25;
  font-size: clamp(2rem, 4.6vw, 3.4rem);
  font-feature-settings: "palt";
}
html[lang="ja"] h2 {
  letter-spacing: 0;
  line-height: 1.4;
  max-width: 32ch;
  font-feature-settings: "palt";
}
html[lang="ja"] h3 { letter-spacing: 0; line-height: 1.5; }
.hero-label a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: var(--accent-dim);
}
.hero-label a:hover { color: var(--text); }

/* ---------------- responsive ---------------- */

@media (max-width: 1080px) {
  .site-nav { display: none; }
}

@media (max-width: 960px) {
  .card-grid.three { grid-template-columns: 1fr 1fr; }
  .process-list { grid-template-columns: 1fr 1fr; row-gap: 2.5rem; }
  .stats-row { grid-template-columns: 1fr 1fr; row-gap: 2.5rem; }
}

@media (max-width: 640px) {
  .section { padding-block: 80px; }
  .card-grid.three,
  .process-list,
  .stats-row { grid-template-columns: 1fr; }
  .hero-content { padding-block: 120px 64px; }
  .header-cta { display: none; }
  .credential-strip .sep { margin-inline: 0.45em; }
}

/* Mobile: never show the WebGL canvas, keep the static SVG */
@media (max-width: 767px) {
  .hero-scene canvas { display: none; }
  .hero.is-live .hero-static { opacity: 1; }
}

/* ---------------- reduced motion ---------------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
  .hero-scene canvas { display: none; }
  .hero.is-live .hero-static { opacity: 1; }
  .card:hover, .btn:hover { transform: none; }
}
