/* ========================================
   Synlai Design System
   - High-end × Near-future × Natural
   - Dark / Cream alternating theme system
   ======================================== */

:root {
  /* ----- Cream theme palette ----- */
  --cream-bg:        #f5f0e6;
  --cream-bg-alt:    #ebe5d6;
  --cream-surface:   #ffffff;
  --cream-text:      #14140f;
  --cream-text-dim:  #5a584f;
  --cream-text-mute: #8d8b80;
  --cream-border:    rgba(20, 20, 15, 0.08);
  --cream-border-strong: rgba(20, 20, 15, 0.16);

  /* ----- Ink (deep midnight navy) theme palette ----- */
  --ink-bg:        #0c1424;
  --ink-bg-alt:    #111a2d;
  --ink-surface:   #161f35;
  --ink-text:      #f5f0e6;
  --ink-text-dim:  rgba(245, 240, 230, 0.55);
  --ink-text-mute: rgba(245, 240, 230, 0.35);
  --ink-border:    rgba(245, 240, 230, 0.08);
  --ink-border-strong: rgba(245, 240, 230, 0.18);

  /* ----- Accent (champagne gold — high-brand) ----- */
  --accent:           #b8956a;
  --accent-light:     #d4b896;
  --accent-deep:      #9a7c54;
  --accent-soft:      rgba(184, 149, 106, 0.12);
  --accent-gradient:  linear-gradient(135deg, #9a7c54 0%, #b8956a 50%, #d4b896 100%);
  --accent-gradient-soft: linear-gradient(135deg, rgba(154,124,84,0.18) 0%, rgba(212,184,150,0.12) 100%);
  --accent-glow:      0 0 80px rgba(184, 149, 106, 0.20);

  /* ----- Tech accent (near-future overlay) ----- */
  --tech:             #5a9bb5;
  --tech-dim:         rgba(90, 155, 181, 0.5);
  --tech-glow:        rgba(90, 155, 181, 0.3);

  /* ----- Backward-compat tokens (preserve existing pages) ----- */
  --color-text-primary:   var(--cream-text);
  --color-text-secondary: var(--cream-text-dim);
  --color-text-tertiary:  var(--cream-text-mute);
  --color-bg-primary:     var(--cream-bg);
  --color-bg-secondary:   var(--cream-bg-alt);
  --color-bg-white:       var(--cream-surface);
  --color-bg-dark:        var(--ink-bg);
  --color-bg-dark-secondary: var(--ink-bg-alt);
  --color-border-light:   var(--cream-border-strong);
  --color-border-subtle:  var(--cream-border);
  --color-accent:         var(--accent);
  --color-accent-hover:   var(--accent-deep);
  --color-accent-subtle:  var(--accent-soft);

  /* ----- Radii ----- */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 14px;
  --radius-xl: 24px;
  --radius-pill: 999px;

  /* ----- Shadows (cream surface) ----- */
  --shadow-sm: 0 1px 2px rgba(20, 20, 15, 0.04);
  --shadow-card: 0 4px 24px rgba(20, 20, 15, 0.06);
  --shadow-elevated: 0 12px 40px rgba(20, 20, 15, 0.12);
  --shadow-deep: 0 24px 64px rgba(20, 20, 15, 0.18);

  /* ----- Max widths ----- */
  --max-width-content: 980px;
  --max-width-wide:    1180px;
  --max-width-narrow:  720px;
  --max-width-edit:    640px;

  /* ----- Motion ----- */
  --ease-out-expo:   cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out-quart:  cubic-bezier(0.25, 1, 0.5, 1);
  --ease-in-out-cubic: cubic-bezier(0.65, 0, 0.35, 1);
  --duration-quick:  0.25s;
  --duration-base:   0.5s;
  --duration-slow:   0.9s;
  --duration-reveal: 1.1s;

  /* ----- Fonts (sans-only system; high-end via weight + tracking) ----- */
  --font-sans:    'Plus Jakarta Sans', 'Zen Kaku Gothic New', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Plus Jakarta Sans', 'Zen Kaku Gothic New', 'Inter', -apple-system, sans-serif;
  --font-mono:    'JetBrains Mono', 'SF Mono', Menlo, monospace;
}

/* ========================================
   Reset & Base
   ======================================== */

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--cream-bg);
  color: var(--cream-text);
  line-height: 1.8;
  font-size: 16px;
  font-weight: 400;
  letter-spacing: 0.01em;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-feature-settings: 'palt' 1, 'kern' 1;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
}

::selection {
  background: var(--accent);
  color: #fff;
}

/* ========================================
   Theme System (alternating sections)
   ======================================== */

.theme-ink {
  --section-bg:        var(--ink-bg);
  --section-bg-alt:    var(--ink-bg-alt);
  --section-surface:   var(--ink-surface);
  --section-text:      var(--ink-text);
  --section-text-dim:  var(--ink-text-dim);
  --section-text-mute: var(--ink-text-mute);
  --section-border:    var(--ink-border);
  --section-border-strong: var(--ink-border-strong);
  --section-on-accent: #fff;
  background: var(--section-bg);
  color: var(--section-text);
}

.theme-cream {
  --section-bg:        var(--cream-bg);
  --section-bg-alt:    var(--cream-bg-alt);
  --section-surface:   var(--cream-surface);
  --section-text:      var(--cream-text);
  --section-text-dim:  var(--cream-text-dim);
  --section-text-mute: var(--cream-text-mute);
  --section-border:    var(--cream-border);
  --section-border-strong: var(--cream-border-strong);
  --section-on-accent: #fff;
  background: var(--section-bg);
  color: var(--section-text);
}

/* ========================================
   Typography Utilities
   ======================================== */

.display-heading {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.15;
  font-feature-settings: 'palt' 1, 'kern' 1;
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
  position: relative;
  padding-left: 28px;
}

.eyebrow::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  width: 20px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}

.text-display {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.15;
}

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

/* ========================================
   Section base (works in both themes)
   ======================================== */

section {
  position: relative;
  padding: 140px 32px;
  isolation: isolate;
}

.section-inner {
  max-width: var(--max-width-wide);
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.section-header {
  text-align: center;
  margin-bottom: 80px;
  max-width: var(--max-width-narrow);
  margin-left: auto;
  margin-right: auto;
}

.section-label {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(32px, 4.4vw, 52px);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.022em;
  color: var(--section-text, var(--cream-text));
  margin-bottom: 24px;
  font-feature-settings: 'palt' 1, 'kern' 1;
}

.section-desc {
  font-size: 18px;
  color: var(--section-text-dim, var(--cream-text-dim));
  max-width: var(--max-width-edit);
  margin: 0 auto;
  line-height: 1.75;
}

/* ========================================
   PC-only line break utility
   - <br class="pc-only"> はモバイル幅では非表示
   - デスクトップで意図的に改行したい箇所にだけ使う
   ======================================== */
@media (max-width: 640px) {
  br.pc-only {
    display: none;
  }
}

/* ========================================
   Text wrapping: avoid orphan characters
   - balance: 短文向け（タイトル・サブ・ラベル等、行数少）
   - pretty: 長文向け（本文・説明、行末1文字残り防止）
   - Modern browsers (Chrome 114+, Firefox 121+, Safari 17.5+)
   - Falls back gracefully (ignored) on older browsers
   ======================================== */
h1, h2, h3, h4, h5, h6,
.section-title,
.section-desc,
.mission-text,
.mission-sub,
.vision-text,
.cta-title,
.cta-desc,
.navi-cta-title,
.navi-cta-desc,
.navi-hero-sub,
.at-hero-sub,
.svc-hero-sub,
.svc-cta-title,
.svc-cta-desc,
.at-cta-title,
.at-cta-desc,
.rep-hero p,
[class*="hero-sub"],
[class*="cta-title"],
[class*="cta-desc"],
/* AI開発受託 LP — 孤立文字対策（短文系） */
.btn-cta,
.ai-section-title,
.ai-section-lead,
.ai-section-label,
.ai-hero-quote,
.ai-hero-note,
.ai-offer-badge-headline,
.ai-offer-badge-sub,
.ai-hero-badge span,
.ai-pain-card-quote,
.ai-pain-closing,
.ai-pillar-title,
.ai-pillar-note,
.ai-message-headline,
.ai-message-sign,
.ai-flow-step-title,
.ai-flow-step-note,
.ai-flow-zone-name,
.ai-flow-zone-label,
.ai-flow-footnote,
.ai-results-row-name,
.ai-results-row-genre,
.ai-results-row-text,
.ai-results-link-wrap,
.ai-pricing-card-title,
.ai-pricing-card-key,
.ai-pricing-card-value,
.ai-pricing-note,
.ai-faq-q,
.ai-final-quote,
.ai-final-title,
.ai-final-sub,
.ai-final-lead,
.ai-final-note,
.ai-company-link-wrap {
  text-wrap: balance;
}

/* AI開発受託 LP — 孤立文字対策（長文系） */
.ai-pain-card-body,
.ai-pain-card-resp p,
.ai-pillar-body,
.ai-message-text,
.ai-message-body,
.ai-flow-step-desc,
.ai-faq-a {
  text-wrap: pretty;
}

/* ========================================
   Reveal Animations — REMOVED
   All [data-reveal] elements are now always visible. The data-reveal
   attribute is kept for HTML-level annotation only; no styling effects.
   ======================================== */

/* ========================================
   Ambient Background (very subtle gradient)
   - Calm. Used as a base wash on hero only.
   ======================================== */

.gradient-mesh {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.gradient-mesh::before,
.gradient-mesh::after {
  content: '';
  position: absolute;
  width: 70vmax;
  height: 70vmax;
  border-radius: 50%;
  filter: blur(140px);
  opacity: 0.10;
  will-change: transform;
  animation: float-mesh 40s var(--ease-in-out-cubic) infinite;
}

.gradient-mesh::before {
  background: radial-gradient(circle at 30% 30%, var(--accent) 0%, transparent 70%);
  top: -30%;
  left: -20%;
}

.gradient-mesh::after {
  background: radial-gradient(circle at 70% 70%, var(--accent-deep) 0%, transparent 70%);
  bottom: -30%;
  right: -20%;
  animation-delay: -20s;
}

.gradient-mesh--soft::before,
.gradient-mesh--soft::after {
  opacity: 0.04;
}

@keyframes float-mesh {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  33%      { transform: translate(6%, -4%) rotate(12deg); }
  66%      { transform: translate(-4%, 6%) rotate(-10deg); }
}

@media (prefers-reduced-motion: reduce) {
  .gradient-mesh::before,
  .gradient-mesh::after {
    animation: none;
  }
}

/* ========================================
   Flow Lines (wind-like flowing lines across the site)
   - The main "near-future" motion element
   - Layered curves drifting slowly via stroke-dashoffset
   ======================================== */

/* Site-wide ambient flow — replaced by neural network canvas */
.site-flow {
  display: none;
}

.site-flow svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

/* Section-level flow — replaced by neural network canvas */
.flow-lines {
  display: none;
}

.flow-lines svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.flow-line {
  fill: none;
  stroke-width: 0.6;
  stroke-linecap: round;
}

/* The rails are static, very faint visible lines.
   Theme is determined by the CONTAINING section (theme-ink/theme-cream),
   OR for site-flow by an explicit `.flow-ink`/`.flow-cream` class that
   only affects flow descendants — never the bg/color of site-flow itself. */
.theme-ink .flow-line,
.flow-ink .flow-line,
.theme-ink .flow-lines .flow-line {
  stroke: rgba(245, 240, 230, 0.06);
}

.theme-cream .flow-line,
.flow-cream .flow-line,
.theme-cream .flow-lines .flow-line {
  stroke: rgba(184, 149, 106, 0.10);
}

/* Tiny light point that travels along its parent rail via SVG <animateMotion>.
   The dot itself is very small; the glow (drop-shadow halo) is what is read. */
.flow-orb {
  filter:
    drop-shadow(0 0 3px currentColor)
    drop-shadow(0 0 10px currentColor)
    drop-shadow(0 0 24px currentColor);
}

.theme-ink .flow-orb,
.flow-ink .flow-orb,
.theme-ink .flow-lines .flow-orb {
  fill: #ffffff;
  color: rgba(212, 184, 150, 1);
}

.theme-cream .flow-orb,
.flow-cream .flow-orb,
.theme-cream .flow-lines .flow-orb {
  fill: #9a7c54;
  color: rgba(184, 149, 106, 0.9);
}

@media (prefers-reduced-motion: reduce) {
  .flow-orb {
    display: none;
  }
}

/* Neural Network Canvas (replaces SVG flow system) */
.neural-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  mix-blend-mode: screen;
}

@media (prefers-reduced-motion: reduce) {
  .neural-canvas {
    display: none;
  }
}

/* Make sure section-inner sits above flows */
section > .section-inner,
section > .hero-inner,
section > .svc-hero-inner,
section > .navi-hero-inner,
section > .ai-hero-inner,
section > .mission-inner {
  position: relative;
  z-index: 2;
}

/* ========================================
   Grid background (optional near-future overlay)
   ======================================== */

.grid-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(to right, var(--section-border) 1px, transparent 1px),
    linear-gradient(to bottom, var(--section-border) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse at center, rgba(0,0,0,0.4) 0%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at center, rgba(0,0,0,0.4) 0%, transparent 70%);
  z-index: 0;
}

/* ========================================
   Header (adaptive, scroll-aware)
   ======================================== */

header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(10, 10, 12, 0);
  border-bottom: 1px solid transparent;
  transition:
    background var(--duration-base) var(--ease-out-quart),
    border-color var(--duration-base) var(--ease-out-quart),
    padding var(--duration-base) var(--ease-out-quart);
}

header.is-scrolled {
  background: rgba(12, 20, 36, 0.85);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border-bottom-color: var(--ink-border);
}

/*
 * 最初のセクションが cream テーマのページ（contact / thanks / privacy / terms など）では、
 * 透明ヘッダー + 白ロゴが cream 背景と同化して見えなくなる。
 * そのため、cream-top ページではスクロール前から dark backdrop を適用してヘッダーを可読にする。
 */
body.first-section-cream header {
  background: rgba(12, 20, 36, 0.85);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border-bottom-color: var(--ink-border);
}

.header-inner {
  max-width: var(--max-width-wide);
  margin: 0 auto;
  padding: 20px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: padding var(--duration-base) var(--ease-out-quart);
}

header.is-scrolled .header-inner {
  padding: 14px 32px;
}

.logo {
  display: flex;
  align-items: center;
  text-decoration: none;
  position: relative;
  transition: opacity var(--duration-quick) ease;
}

.logo:hover {
  opacity: 0.7;
}

.logo-img {
  height: 34px;
  width: auto;
  /* Force light logo always since header is always dark */
  filter: brightness(0) invert(1);
  transition: height var(--duration-base) var(--ease-out-quart);
}

header.is-scrolled .logo-img {
  height: 28px;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 36px;
}

.header-nav a {
  color: rgba(245, 240, 230, 0.7);
  text-decoration: none;
  font-weight: 500;
  font-size: 14px;
  letter-spacing: 0.01em;
  position: relative;
  transition: color var(--duration-quick) var(--ease-out-quart);
}

.header-nav a::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -6px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform var(--duration-base) var(--ease-out-expo);
}

.header-nav a:hover,
.header-nav a.active {
  color: var(--ink-text);
}

.header-nav a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

.header-cta {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Header nav CTA button (e.g., お問い合わせ) */
.header-nav .header-nav-cta {
  padding: 8px 18px;
  background: var(--accent);
  color: var(--ink-bg);
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.02em;
  transition:
    background var(--duration-base) var(--ease-out-expo),
    transform var(--duration-base) var(--ease-out-expo),
    box-shadow var(--duration-base) var(--ease-out-expo);
}

.header-nav .header-nav-cta:hover {
  background: var(--accent-light);
  color: var(--ink-bg);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(184, 149, 106, 0.28);
}

.header-nav .header-nav-cta::after {
  display: none;
}

/* ========================================
   Header Burger (mobile)
   ======================================== */

.header-burger {
  display: none;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 8px;
  width: 40px;
  height: 40px;
  flex-direction: column;
  justify-content: space-around;
  align-items: center;
  position: relative;
  z-index: 1002;
}

.header-burger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: rgba(245, 240, 230, 0.9);
  border-radius: 2px;
  transition:
    transform 0.4s var(--ease-out-expo),
    opacity 0.3s ease,
    background 0.3s ease;
}

.header-burger.is-open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.header-burger.is-open span:nth-child(2) {
  opacity: 0;
}

.header-burger.is-open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Menu (drop-down from header) */
.mobile-menu {
  position: fixed;
  top: 60px;
  left: 0;
  right: 0;
  background: rgba(10, 16, 28, 0.985);
  backdrop-filter: blur(24px) saturate(140%);
  -webkit-backdrop-filter: blur(24px) saturate(140%);
  z-index: 999;
  max-height: calc(100vh - 60px);
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-12px);
  transition:
    opacity 0.35s var(--ease-out-expo),
    transform 0.4s var(--ease-out-expo),
    visibility 0.4s;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.30);
  border-bottom: 1px solid rgba(245, 240, 230, 0.08);
}

.mobile-menu.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* ヘッダーをドロップダウンの上に残し、メニュー開閉時はダーク背景に強制 */
body.menu-open header {
  background: rgba(10, 16, 28, 0.985);
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);
  border-bottom-color: transparent;
}

@media (max-width: 480px) {
  .mobile-menu {
    top: 56px;
    max-height: calc(100vh - 56px);
  }
}

.mobile-menu.is-open {
  opacity: 1;
  visibility: visible;
}

.mobile-menu-inner {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  padding: 14px 28px 28px;
  gap: 0;
  box-sizing: border-box;
}

.mobile-menu a {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 500;
  color: var(--ink-text);
  text-decoration: none;
  letter-spacing: -0.01em;
  padding: 22px 4px;
  border-bottom: 1px solid rgba(245, 240, 230, 0.10);
  display: flex;
  align-items: center;
  justify-content: space-between;
  opacity: 0;
  transform: translateY(20px);
  transition:
    opacity 0.7s var(--ease-out-expo),
    transform 0.7s var(--ease-out-expo),
    color 0.3s ease,
    padding-left 0.3s ease;
}

.mobile-menu a::after {
  content: '→';
  font-weight: 400;
  font-size: 18px;
  color: var(--accent-light);
  opacity: 0.7;
  transition: transform 0.4s var(--ease-out-expo), opacity 0.3s ease;
}

.mobile-menu a:hover::after,
.mobile-menu a:active::after {
  transform: translateX(4px);
  opacity: 1;
}

.mobile-menu.is-open a {
  opacity: 1;
  transform: translateY(0);
}

.mobile-menu.is-open a:nth-child(1) { transition-delay: 0.15s; }
.mobile-menu.is-open a:nth-child(2) { transition-delay: 0.25s; }
.mobile-menu.is-open a:nth-child(3) { transition-delay: 0.35s; }
.mobile-menu.is-open a:nth-child(4) { transition-delay: 0.45s; }
.mobile-menu.is-open a:nth-child(5) { transition-delay: 0.55s; }

.mobile-menu a:hover {
  color: var(--accent-light);
}

body.menu-open {
  overflow: hidden;
}

/* ========================================
   Buttons
   ======================================== */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-pill);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.01em;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  overflow: hidden;
  transition:
    transform var(--duration-base) var(--ease-out-expo),
    box-shadow var(--duration-base) var(--ease-out-expo),
    border-color var(--duration-base) var(--ease-out-expo),
    background var(--duration-base) var(--ease-out-expo),
    color var(--duration-base) var(--ease-out-expo);
}

.btn > * {
  position: relative;
  z-index: 1;
}

.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, 0.18) 50%, transparent 70%);
  transform: translateX(-120%);
  transition: transform 0.9s var(--ease-out-expo);
  pointer-events: none;
}

.btn:hover::before {
  transform: translateX(120%);
}

.btn-primary {
  background: var(--ink-bg);
  color: var(--ink-text);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-elevated);
}

.btn-ghost {
  background: transparent;
  color: rgba(245, 240, 230, 0.7);
  border-color: transparent;
}

.btn-ghost:hover {
  color: var(--ink-text);
  background: rgba(245, 240, 230, 0.05);
}

.btn-outline {
  background: transparent;
  color: var(--section-text, var(--cream-text));
  border-color: var(--section-border-strong, var(--cream-border-strong));
}

.btn-outline:hover {
  border-color: var(--section-text, var(--cream-text));
  transform: translateY(-2px);
}

.btn-white {
  background: var(--cream-bg);
  color: var(--cream-text);
}

.btn-white:hover {
  background: #fff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-elevated);
}

.btn-outline-white {
  background: transparent;
  color: var(--ink-text);
  border-color: rgba(245, 240, 230, 0.25);
}

.btn-outline-white:hover {
  border-color: rgba(245, 240, 230, 0.6);
  transform: translateY(-2px);
}

.btn-large {
  padding: 16px 32px;
  font-size: 15px;
}

.btn-arrow::after {
  content: '→';
  font-weight: 400;
  transition: transform var(--duration-base) var(--ease-out-expo);
}

.btn-arrow:hover::after {
  transform: translateX(4px);
}

/* ========================================
   Cards (theme-aware)
   ======================================== */

.card {
  position: relative;
  padding: 36px 32px;
  border-radius: var(--radius-lg);
  background: var(--section-surface, var(--cream-surface));
  border: 1px solid var(--section-border, var(--cream-border));
  transition:
    transform var(--duration-base) var(--ease-out-expo),
    box-shadow var(--duration-base) var(--ease-out-expo),
    border-color var(--duration-base) var(--ease-out-expo);
}

.card:hover {
  transform: translateY(-3px);
  border-color: var(--section-border-strong, var(--cream-border-strong));
}

.theme-cream .card:hover {
  box-shadow: var(--shadow-card);
}

.theme-ink .card:hover {
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.card-num {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 20px;
}

.card-title {
  font-size: 21px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--section-text, var(--cream-text));
  margin-bottom: 12px;
  line-height: 1.35;
}

.card-desc {
  font-size: 15px;
  color: var(--section-text-dim, var(--cream-text-dim));
  line-height: 1.75;
}

/* ========================================
   Page Header (subpages)
   ======================================== */

.page-header {
  background: var(--cream-bg);
  padding: 180px 32px 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.page-header h1 {
  font-family: var(--font-display);
  font-size: clamp(40px, 5vw, 64px);
  font-weight: 500;
  color: var(--cream-text);
  margin-bottom: 16px;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.page-header p {
  color: var(--cream-text-dim);
  font-size: 17px;
  max-width: var(--max-width-edit);
  margin: 0 auto;
  line-height: 1.75;
}

/* ========================================
   Content (legal pages)
   ======================================== */

.content {
  max-width: 800px;
  margin: 0 auto;
  padding: 80px 32px 140px;
  background: var(--cream-bg);
}

.content h2 {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 500;
  color: var(--cream-text);
  margin: 56px 0 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--cream-border);
  letter-spacing: -0.01em;
}

.content h2:first-child {
  margin-top: 0;
}

.content h3 {
  font-size: 18px;
  font-weight: 600;
  color: var(--cream-text);
  margin: 36px 0 12px;
}

.content p {
  margin-bottom: 16px;
  color: var(--cream-text-dim);
}

.content ul, .content ol {
  margin: 16px 0;
  padding-left: 24px;
}

.content li {
  margin-bottom: 8px;
  color: var(--cream-text-dim);
}

.update-date {
  text-align: right;
  color: var(--cream-text-mute);
  font-size: 14px;
  margin-bottom: 32px;
  font-family: var(--font-mono);
}

/* ========================================
   Footer (always ink theme)
   ======================================== */

footer {
  background: var(--ink-bg);
  color: var(--ink-text);
  padding: 80px 32px 36px;
  position: relative;
  overflow: hidden;
}

footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent) 50%, transparent);
  opacity: 0.4;
}

.footer-inner {
  max-width: var(--max-width-wide);
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 56px;
  margin-bottom: 64px;
}

.footer-brand {
  max-width: 320px;
}

.footer-logo {
  display: inline-block;
  margin-bottom: 20px;
  text-decoration: none;
}

.footer-logo-img {
  height: 36px;
  width: auto;
}

.footer-desc {
  color: var(--ink-text-dim);
  font-size: 14px;
  line-height: 1.75;
}

.footer-col h4 {
  color: var(--ink-text);
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 20px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-links a {
  color: var(--ink-text-dim);
  text-decoration: none;
  font-size: 14px;
  transition: color var(--duration-quick) ease, padding-left var(--duration-base) var(--ease-out-expo);
}

.footer-links a:hover {
  color: var(--ink-text);
  padding-left: 4px;
}

.footer-bottom {
  padding-top: 32px;
  border-top: 1px solid var(--ink-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-copyright {
  color: var(--ink-text-mute);
  font-size: 13px;
  font-family: var(--font-mono);
  letter-spacing: 0.02em;
}

.footer-legal {
  display: flex;
  gap: 28px;
}

.footer-legal a {
  color: var(--ink-text-mute);
  text-decoration: none;
  font-size: 13px;
  transition: color var(--duration-quick) ease;
}

.footer-legal a:hover {
  color: var(--ink-text-dim);
}

/* ========================================
   Tables
   ======================================== */

.company-table,
.info-table {
  width: 100%;
  border-collapse: collapse;
}

.company-table tr,
.info-table tr {
  border-bottom: 1px solid var(--cream-border);
}

.company-table th, .company-table td,
.info-table th, .info-table td {
  padding: 24px 20px;
  text-align: left;
  vertical-align: top;
}

.company-table th,
.info-table th {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--cream-text-mute);
  width: 220px;
}

.company-table td,
.info-table td {
  color: var(--cream-text);
}

/* ========================================
   Icon Circle
   ======================================== */

.icon-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  letter-spacing: 0.02em;
  flex-shrink: 0;
}

.icon-circle-dark {
  background: rgba(245, 240, 230, 0.08);
  color: rgba(245, 240, 230, 0.7);
}

/* ========================================
   Stat
   ======================================== */

.stat {
  text-align: center;
  padding: 24px;
}

.stat-value {
  font-family: var(--font-display);
  font-size: clamp(48px, 6vw, 72px);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1;
  margin-bottom: 12px;
  color: var(--section-text, var(--cream-text));
}

.stat-label {
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--section-text-mute, var(--cream-text-mute));
}

/* ========================================
   Responsive
   ======================================== */

@media (max-width: 1024px) {
  section {
    padding: 100px 28px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 40px;
  }
}

@media (max-width: 768px) {
  body {
    font-size: 16px;
  }

  .header-inner {
    padding: 16px 20px;
  }

  header.is-scrolled .header-inner {
    padding: 12px 20px;
  }

  .header-nav {
    display: none;
  }

  .header-burger {
    display: flex;
  }

  .header-cta .btn-ghost {
    display: none;
  }

  section {
    padding: 80px 20px;
  }

  .section-header {
    margin-bottom: 56px;
  }

  .section-title {
    font-size: clamp(28px, 7vw, 44px);
  }

  .page-header {
    padding: 140px 20px 60px;
  }

  .content {
    padding: 60px 20px 100px;
  }

  .company-table th, .company-table td,
  .info-table th, .info-table td {
    display: block;
    width: 100%;
    padding: 16px 20px;
  }

  .company-table th, .info-table th {
    border-bottom: none;
    padding-bottom: 4px;
  }

  .company-table td, .info-table td {
    padding-top: 4px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  .footer-legal {
    flex-wrap: wrap;
    justify-content: center;
  }
}
