/*
Theme Name: NPC ABC Theme
Theme URI: https://n-pc.jp/
Author: NPC
Author URI: https://n-pc.jp/
Description: A/B/Cデザイン切り替え機能付きWordPressテーマ - Business/Gamer/Cosmeの3パターン
Version: 1.2.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: npc-abc-theme
Tags: custom-colors, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready
*/

/* ============================================
   NPC ABC Theme System
   A: Business (ビジネス)
   B: Gamer (ゲーマー)
   C: Cosme (コスメ)
============================================ */

/* CSS Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  overflow-x: hidden; /* 左右ブレ防止 */
  overflow-y: scroll !important; /* スクロールバーを常時表示 */
  /* Firefox用 */
  scrollbar-width: thin;
  scrollbar-color: var(--accent) var(--background-secondary);
}

body {
  overflow-x: hidden;
}

/* カスタムスクロールバー — macOSでも常時表示 */
html::-webkit-scrollbar {
  -webkit-appearance: none;
  width: 8px !important;
}

html::-webkit-scrollbar-track {
  background: var(--background-secondary);
}

html::-webkit-scrollbar-thumb {
  background: var(--accent);
  border-radius: 4px;
}

html::-webkit-scrollbar-thumb:hover {
  background: var(--accent-hover);
}

/* Gamer: ネオンスクロールバー */
[data-theme="gamer"] ::-webkit-scrollbar-thumb {
  background: var(--neon-cyan);
  box-shadow: 0 0 10px var(--neon-cyan);
}

/* Cosme: パステルグラデーション */
[data-theme="cosme"] ::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #ffb6c1, #ffb4a2);
}

@media (max-width: 640px) {
  html {
    font-size: 14px;
  }
}

body {
  font-family: 'Noto Sans JP', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
  line-height: 1.6 !important;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background-color: var(--background) !important;
  color: var(--foreground) !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* メインコンテンツを伸ばしてフッターを下に押し付ける */
.site-main,
#main-content,
.main {
  flex: 1;
}

/* Apply theme styles directly to html for higher specificity */
html, html[data-theme] {
  background-color: var(--background) !important;
}

html[data-theme] body {
  background-color: var(--background) !important;
  color: var(--foreground) !important;
}

/* WordPress overrides */
.wp-site-blocks {
  padding: 0 !important;
}

body.home,
body.page,
body.single,
body.archive {
  background-color: var(--background) !important;
  color: var(--foreground) !important;
}

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

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

/* ナビ・UI用リストのみリセット。本文コンテンツのリストは維持 */
.nav-menu, .mobile-nav-menu, .footer-nav-list,
.social-links, .skills-tags, .commentlist, .comment-list,
.service-features, .process-steps, .contact-methods,
.theme-buttons, .blog-archive-categories {
  list-style: none;
  padding: 0;
  margin: 0;
}

/* ============================================
   CSS Variables - Default Theme (Business)
============================================ */
:root {
  /* Colors */
  --background: #ffffff;
  --background-secondary: #f8f9fa;
  --foreground: #1a1a1a;
  --foreground-secondary: #5a5a5a;
  --accent: #0066cc;
  --accent-hover: #004d99;
  --accent-light: #e6f0fa;
  --card: #ffffff;
  --card-foreground: #1a1a1a;
  --card-border: #e8e8e8;
  --border: #e8e8e8;
  --input: #f5f5f5;

  /* Hero */
  --hero-bg: linear-gradient(180deg, #ffffff 0%, #f0f4f8 100%);
  --hero-text: #1a1a1a;
  --hero-text-secondary: #5a5a5a;
  --hero-accent: #0066cc;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.12);

  /* Animation */
  --transition-base: 0.3s ease;
  --transition-slow: 0.6s ease;

  /* Typography */
  --font-heading: 'Noto Serif JP', serif;
  --font-body: 'Noto Sans JP', sans-serif;

  /* Radius */
  --radius: 0.375rem;
  --radius-lg: 0.75rem;
  --radius-full: 9999px;

  /* Decoration */
  --decoration-opacity: 0.1;
  --glow-color: transparent;
  --glow-intensity: 0;

  /* Spacing */
  --section-padding: 6rem;
  --section-padding-md: 8rem;
  --container-width: 1500px;
}

/* ============================================
   Theme A: Business (ビジネス・スタンダード)
============================================ */
[data-theme="business"] {
  --background: #ffffff;
  --background-secondary: #f8f9fa;
  --foreground: #1a1a1a;
  --foreground-secondary: #5a5a5a;
  --accent: #0066cc;
  --accent-hover: #004d99;
  --accent-light: #e6f0fa;
  --card: #ffffff;
  --card-foreground: #1a1a1a;
  --card-border: #e8e8e8;
  --border: #e8e8e8;
  --hero-bg: linear-gradient(180deg, #ffffff 0%, #f0f4f8 100%);
  --hero-text: #1a1a1a;
  --hero-text-secondary: #5a5a5a;
  --hero-accent: #0066cc;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.12);
  --radius: 0.375rem;

  /* Decoration */
  --decoration-opacity: 0.08;
  --glow-color: transparent;
  --glow-intensity: 0;
}

[data-theme="business"] body {
  background-color: var(--background);
  color: var(--foreground);
}

/* ============================================
   Theme B: Gamer (プロゲーマー・サイバーパンク)
============================================ */
[data-theme="gamer"] {
  --background: #0a0a0f;
  --background-secondary: #12121a;
  --foreground: #e0e0e0;
  --foreground-secondary: #888888;
  --accent: #00ffff;
  --accent-hover: #00cccc;
  --accent-light: rgba(0, 255, 255, 0.1);
  --card: #15151f;
  --card-foreground: #e0e0e0;
  --card-border: #2a2a3a;
  --border: #2a2a3a;
  --hero-bg: radial-gradient(ellipse at center, #0f0f1a 0%, #050510 100%);
  --hero-text: #ffffff;
  --hero-text-secondary: #00ffff;
  --hero-accent: #ff00ff;
  --shadow-sm: 0 0 10px rgba(0, 255, 255, 0.1);
  --shadow-md: 0 0 20px rgba(0, 255, 255, 0.15);
  --shadow-lg: 0 0 40px rgba(0, 255, 255, 0.2);
  --radius: 0;

  /* Neon colors */
  --neon-cyan: #00ffff;
  --neon-magenta: #ff00ff;
  --neon-green: #39ff14;
  --neon-yellow: #ffff00;

  /* Decoration */
  --decoration-opacity: 0.3;
  --glow-color: #00ffff;
  --glow-intensity: 1;
}

[data-theme="gamer"] body {
  background-color: var(--background);
  color: var(--foreground);
}

/* ============================================
   Theme C: Cosme (清楚系コスメ女子)
============================================ */
[data-theme="cosme"] {
  --background: #fffaf8;
  --background-secondary: #fff5f0;
  --foreground: #4a3f3f;
  --foreground-secondary: #8a7575;
  --accent: #ff6b9d;
  --accent-hover: #ff4785;
  --accent-light: rgba(255, 107, 157, 0.1);
  --card: #ffffff;
  --card-foreground: #4a3f3f;
  --card-border: #ffe4e8;
  --border: #ffe4e8;
  --hero-bg: linear-gradient(135deg, #fff5f5 0%, #ffe8e0 50%, #fff0e8 100%);
  --hero-text: #4a3f3f;
  --hero-text-secondary: #8a7575;
  --hero-accent: #ff6b9d;
  --shadow-sm: 0 2px 8px rgba(255, 107, 157, 0.08);
  --shadow-md: 0 8px 24px rgba(255, 107, 157, 0.12);
  --shadow-lg: 0 16px 48px rgba(255, 107, 157, 0.15);
  --radius: 1.5rem;

  /* Pastel colors */
  --pastel-pink: #ffb6c1;
  --pastel-orange: #ffcc99;
  --pastel-peach: #ffdab9;
  --pastel-coral: #ffb4a2;

  /* Decoration */
  --decoration-opacity: 0.15;
  --glow-color: #ffb6c1;
  --glow-intensity: 0.5;
}

[data-theme="cosme"] body {
  background-color: var(--background);
  color: var(--foreground);
}

/* ============================================
   Layout Utilities
============================================ */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 768px) {
  .container {
    padding: 0 2rem;
  }
}

.section {
  padding: var(--section-padding) 0;
  position: relative;
}

@media (max-width: 768px) {
  .section {
    padding: 4rem 0;
  }
}

@media (min-width: 768px) {
  .section {
    padding: var(--section-padding-md) 0;
  }
}

/* Alternate section backgrounds (A/C用: even↔odd入れ替え) */
[data-theme="business"] .section:nth-child(even),
[data-theme="cosme"] .section:nth-child(even) {
  background-color: var(--background);
}

[data-theme="business"] .section:nth-child(odd),
[data-theme="cosme"] .section:nth-child(odd) {
  background-color: var(--background-secondary);
}

/* B (Gamer): 個別指定 */
[data-theme="gamer"] .section {
  background-color: var(--background-secondary);
}

[data-theme="gamer"] .section.services,
[data-theme="gamer"] .section.works,
[data-theme="gamer"] .section.blog {
  background-color: var(--background);
}

[data-theme="gamer"] .section.contact {
  background-color: #12121a;
  position: relative;
}

/* Gamer Contact: 上下のネオンライン（サイドがフェードアウト） */
[data-theme="gamer"] .section.contact::before,
[data-theme="gamer"] .section.contact::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
  pointer-events: none;
}

[data-theme="gamer"] .section.contact::before {
  top: 0;
  background: linear-gradient(90deg, transparent, rgba(0, 255, 255, 0.5), transparent);
}

[data-theme="gamer"] .section.contact::after {
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 0, 255, 0.5), transparent);
}

/* Section background decoration */
.services-bg,
.works-bg,
.process-bg,
.contact-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

/* Gamer共通: セクション背景グリッドオーバーレイ */
.gamer-grid-overlay {
  display: none;
}

[data-theme="gamer"] .gamer-grid-overlay {
  display: block;
  position: absolute;
  inset: 0;
  opacity: 0.05;
  background-image:
    linear-gradient(to right, #00ffff 1px, transparent 1px),
    linear-gradient(to bottom, #00ffff 1px, transparent 1px);
  background-size: 40px 40px;
}

/* Flex utilities */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-2 { gap: 0.5rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }

/* Grid utilities */
.grid { display: grid; }
.grid-cols-1 { grid-template-columns: repeat(1, 1fr); }
.grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid-cols-4 { grid-template-columns: repeat(4, 1fr); }

@media (min-width: 768px) {
  .md\:grid-cols-2 { grid-template-columns: repeat(2, 1fr); }
  .md\:grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 1024px) {
  .lg\:grid-cols-3 { grid-template-columns: repeat(3, 1fr); }
  .lg\:grid-cols-4 { grid-template-columns: repeat(4, 1fr); }
}

/* Text utilities */
.text-center { text-align: center; }
.text-sm { font-size: 0.875rem; }
.text-base { font-size: 1rem; }
.text-lg { font-size: 1.125rem; }
.text-xl { font-size: 1.25rem; }
.text-2xl { font-size: 1.5rem; }
.text-3xl { font-size: 1.875rem; }
.text-4xl { font-size: 2.25rem; }
.text-5xl { font-size: 3rem; }
.font-medium { font-weight: 500; }
.font-bold { font-weight: 700; }

/* Spacing utilities */
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-12 { margin-bottom: 3rem; }
.mb-16 { margin-bottom: 4rem; }
.p-4 { padding: 1rem; }
.p-6 { padding: 1.5rem; }
.p-8 { padding: 2rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.px-8 { padding-left: 2rem; padding-right: 2rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }

/* ============================================
   Component Styles - Header
============================================ */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1.25rem 0;
  transition: all var(--transition-base);
}

.site-header.scrolled {
  padding: 0.75rem 0;
}

[data-theme="business"] .site-header.scrolled {
  background-color: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-sm);
}

[data-theme="gamer"] .site-header.scrolled {
  background-color: rgba(10, 10, 15, 0.95);
  border-bottom: 1px solid rgba(0, 255, 255, 0.2);
}

/* Gamer: ヘッダーCTAボタンは透明背景+borderのみ */
[data-theme="gamer"] .site-header .btn-primary {
  background-color: transparent;
  color: var(--neon-cyan);
  border: 1px solid var(--neon-cyan);
}

[data-theme="gamer"] .site-header .btn-primary:hover {
  background-color: rgba(0, 255, 255, 0.1);
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.3);
}

[data-theme="cosme"] .site-header.scrolled {
  background-color: rgba(255, 250, 248, 0.9);
  box-shadow: var(--shadow-sm);
}

.site-logo {
  font-family: 'Unbounded', var(--font-heading);
  font-size: 1.4rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  transition: color var(--transition-base);
  color: var(--foreground);
}

/* ロゴの「C」だけアクセントカラー */
.logo-text .logo-accent {
  color: var(--accent);
}

[data-theme="gamer"] .logo-text .logo-accent {
  color: var(--neon-cyan);
}

.site-logo:hover {
  color: var(--accent);
}

[data-theme="business"] .site-logo {
  color: var(--foreground);
}

[data-theme="business"] .site-logo:hover {
  color: var(--accent);
}

[data-theme="gamer"] .site-logo {
  color: var(--neon-cyan);
}

[data-theme="cosme"] .site-logo {
  color: var(--foreground);
}

/* Navigation */
.main-nav {
  display: none;
}

@media (min-width: 1024px) {
  .main-nav {
    display: flex;
    align-items: center;
    gap: 2rem;
  }
}

.nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  transition: color var(--transition-base);
  position: relative;
  color: var(--foreground-secondary);
}

.nav-link:hover {
  color: var(--accent);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  transition: width var(--transition-base);
}

.nav-link:hover::after {
  width: 100%;
}

[data-theme="business"] .nav-link {
  color: var(--foreground-secondary);
}

[data-theme="business"] .nav-link:hover {
  color: var(--accent);
}

[data-theme="business"] .nav-link::after {
  background-color: var(--accent);
}

[data-theme="gamer"] .nav-link {
  color: var(--foreground-secondary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.75rem;
}

[data-theme="gamer"] .nav-link:hover {
  color: var(--neon-cyan);
}

[data-theme="gamer"] .nav-link::after {
  background-color: var(--neon-cyan);
  box-shadow: 0 0 10px var(--neon-cyan);
}

[data-theme="cosme"] .nav-link {
  color: var(--foreground-secondary);
}

[data-theme="cosme"] .nav-link:hover {
  color: var(--accent);
}

[data-theme="cosme"] .nav-link::after {
  background: linear-gradient(90deg, var(--accent), #ffb347);
}

/* CTA Button */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all var(--transition-base);
  cursor: pointer;
  border: none;
}

.btn-primary {
  background-color: var(--accent);
  color: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  background-color: var(--accent-hover);
  box-shadow: var(--shadow-lg);
}

[data-theme="business"] .btn-primary {
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
}

[data-theme="business"] .btn-primary:hover {
  background-color: var(--accent-hover);
  box-shadow: var(--shadow-lg);
}

[data-theme="gamer"] .btn-primary {
  background-color: var(--neon-cyan);
  color: #0a0a0f;
}

[data-theme="gamer"] .btn-primary:hover {
  box-shadow: 0 0 30px rgba(0, 255, 255, 0.5);
}

[data-theme="cosme"] .btn-primary {
  background: linear-gradient(90deg, var(--accent), #ffb347);
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-lg);
}

[data-theme="cosme"] .btn-primary:hover {
  opacity: 0.9;
}

.btn-secondary {
  background-color: white;
  border: 1px solid var(--accent);
  color: var(--accent);
  border-radius: var(--radius);
}

.btn-secondary:hover {
  background-color: var(--accent-light);
}

[data-theme="business"] .btn-secondary {
  background-color: white;
  border-color: var(--accent);
  color: var(--accent);
}

[data-theme="business"] .btn-secondary:hover {
  background-color: #f0f4f8;
}

[data-theme="gamer"] .btn-secondary {
  background-color: transparent;
  border-color: var(--neon-magenta);
  color: var(--neon-magenta);
}

[data-theme="gamer"] .btn-secondary:hover {
  background-color: rgba(255, 0, 255, 0.1);
}

[data-theme="cosme"] .btn-secondary {
  background-color: white;
  border-color: #ff6b9d;
  color: #ff6b9d;
  border-radius: var(--radius-full);
}

[data-theme="cosme"] .btn-secondary:hover {
  background-color: #fff5f5;
}

.btn-outline {
  background-color: transparent;
  border: 1px solid var(--accent);
  color: var(--accent);
}

[data-theme="business"] .btn-outline {
  border-radius: var(--radius);
}

[data-theme="business"] .btn-outline:hover {
  background-color: var(--accent-light);
}

[data-theme="gamer"] .btn-outline {
  border-color: var(--neon-magenta);
  color: var(--neon-magenta);
}

[data-theme="gamer"] .btn-outline:hover {
  background-color: rgba(255, 0, 255, 0.1);
}

[data-theme="cosme"] .btn-outline {
  border-radius: var(--radius-full);
}

[data-theme="cosme"] .btn-outline:hover {
  background-color: var(--accent-light);
}

/* Mobile Menu */
.mobile-menu-toggle {
  display: block;
  padding: 0.5rem;
  background: transparent;
  border: none;
  cursor: pointer;
}

@media (min-width: 1024px) {
  .mobile-menu-toggle {
    display: none;
  }
}

[data-theme="business"] .mobile-menu-toggle {
  color: var(--foreground);
}

[data-theme="gamer"] .mobile-menu-toggle {
  color: var(--neon-cyan);
}

[data-theme="cosme"] .mobile-menu-toggle {
  color: var(--accent);
}

/* モバイルナビ: フルスクリーンオーバーレイ */
.mobile-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 999;
  overflow-y: auto;
  padding: 0.75rem 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-nav.active {
  opacity: 1;
  visibility: visible;
}

/* メニュー表示中はスクロール禁止 */
html.menu-open {
  overflow: hidden !important;
}

/* モバイルナビ内のヘッダー部分（ロゴ+閉じるボタン） */
.mobile-nav-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
}

.mobile-nav-close {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  color: var(--foreground);
}

[data-theme="gamer"] .mobile-nav-close {
  color: var(--neon-cyan);
}

@media (min-width: 1024px) {
  .mobile-nav {
    display: none !important;
  }
}

[data-theme="business"] .mobile-nav {
  background-color: #ffffff;
}

[data-theme="gamer"] .mobile-nav {
  background-color: #0a0a0f;
}

[data-theme="cosme"] .mobile-nav {
  background-color: #fffaf8;
}

/* モバイルナビメニュー */
.mobile-nav-menu {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.mobile-nav-menu li {
  border-bottom: 1px solid var(--border);
}

.mobile-nav-menu a,
.mobile-nav-link {
  display: block;
  padding: 1rem 0;
  font-size: 1rem;
  font-weight: 500;
  color: var(--foreground);
  transition: color var(--transition-base);
}

[data-theme="gamer"] .mobile-nav-menu a,
[data-theme="gamer"] .mobile-nav-link {
  color: var(--foreground);
}

[data-theme="gamer"] .mobile-nav-menu a:hover {
  color: var(--neon-cyan);
}

.mobile-cta {
  margin-top: 1.5rem;
  width: 100%;
  justify-content: center;
}

/* ============================================
   Component Styles - Hero
============================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--hero-bg);
}

[data-theme="business"] .hero {
  background: var(--hero-bg);
}

[data-theme="gamer"] .hero {
  background: var(--hero-bg);
}

[data-theme="cosme"] .hero {
  background: var(--hero-bg);
}

/* Hero background elements visibility */
.hero-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.hero-bg-business,
.hero-bg-gamer,
.hero-bg-cosme {
  display: none;
  position: absolute;
  inset: 0;
}

[data-theme="business"] .hero-bg-business { display: block; }
[data-theme="gamer"] .hero-bg-gamer { display: block; }
[data-theme="cosme"] .hero-bg-cosme { display: block; }

/* Business hero shapes */
.hero-bg-business .shape {
  position: absolute;
  border: 2px solid rgba(0, 102, 204, 0.1);
  border-radius: var(--radius-lg);
}

.hero-bg-business .shape-1 {
  width: 128px;
  height: 128px;
  top: 5rem;
  left: 2.5rem;
  animation: shape-rotate-float 20s linear infinite, shape-float-y 4s ease-in-out infinite !important;
}

.hero-bg-business .shape-2 {
  width: 192px;
  height: 192px;
  top: 10rem;
  right: 5rem;
  border-radius: 50%;
  animation: shape-rotate-reverse 25s linear infinite, shape-scale-pulse 5s ease-in-out infinite !important;
}

.hero-bg-business .shape-3 {
  width: 96px;
  height: 96px;
  bottom: 10rem;
  left: 25%;
  background-color: rgba(0, 102, 204, 0.05);
  border: none;
  animation: shape-float-y-lg 6s ease-in-out infinite !important;
}

.hero-bg-business .shape-4 {
  width: 64px;
  height: 64px;
  top: 33%;
  right: 25%;
  border-radius: 0;
  animation: shape-rotate-half 15s linear infinite, shape-float-x 7s ease-in-out infinite !important;
}

@keyframes shape-rotate-float {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes shape-rotate-reverse {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

@keyframes shape-rotate-half {
  from { transform: rotate(0deg); }
  to { transform: rotate(180deg); }
}

@keyframes shape-float-y {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(180deg); }
}

@keyframes shape-float-y-lg {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(30px); }
}

@keyframes shape-float-x {
  0%, 100% { transform: translateX(0) rotate(0deg); }
  50% { transform: translateX(20px) rotate(90deg); }
}

@keyframes shape-scale-pulse {
  0%, 100% { transform: scale(1) rotate(0deg); }
  50% { transform: scale(1.1) rotate(-180deg); }
}

.hero-bg-business .grid-pattern {
  position: absolute;
  inset: 0;
  opacity: 0.03;
  background-image:
    linear-gradient(to right, #0066cc 1px, transparent 1px),
    linear-gradient(to bottom, #0066cc 1px, transparent 1px);
  background-size: 60px 60px;
}

/* Gamer hero elements */
/* サイバーグリッド — Next.js: opacity-20 (0.2) */
.hero-bg-gamer .cyber-grid {
  position: absolute;
  inset: 0;
  opacity: 0.2;
  background-image:
    linear-gradient(to right, #00ffff 1px, transparent 1px),
    linear-gradient(to bottom, #00ffff 1px, transparent 1px);
  background-size: 50px 50px;
  animation: grid-move 3s linear infinite;
}

/* ネオンライン共通 */
.hero-bg-gamer .neon-line {
  position: absolute;
}

/* 水平ライン1: シアン — top: 25% */
.hero-bg-gamer .neon-line-h-1 {
  top: 25%;
  left: 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0, 255, 255, 0.5), transparent);
}

/* 水平ライン2: マゼンタ — top: 75% */
.hero-bg-gamer .neon-line-h-2 {
  top: 75%;
  left: 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 0, 255, 0.5), transparent);
}

/* 垂直ライン1: シアン — left: 25% */
.hero-bg-gamer .neon-line-v-1 {
  position: absolute;
  left: 25%;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(180deg, transparent, rgba(0, 255, 255, 0.3), transparent);
}

/* 垂直ライン2: マゼンタ — right: 25% */
.hero-bg-gamer .neon-line-v-2 {
  position: absolute;
  right: 25%;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(180deg, transparent, rgba(255, 0, 255, 0.3), transparent);
}

/* グローオーブ */
.hero-bg-gamer .glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(48px);
}

/* シアンオーブ — top-20 right-20 w-64 h-64 */
.hero-bg-gamer .glow-orb-cyan {
  width: 16rem;
  height: 16rem;
  top: 5rem;
  right: 5rem;
  background-color: rgba(0, 255, 255, 0.05);
}

/* マゼンタオーブ — bottom-20 left-20 w-64 h-64 */
.hero-bg-gamer .glow-orb-magenta {
  width: 16rem;
  height: 16rem;
  bottom: 5rem;
  left: 5rem;
  background-color: rgba(255, 0, 255, 0.05);
}

.hero-bg-gamer .scanlines {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0, 0, 0, 0.1) 2px,
    rgba(0, 0, 0, 0.1) 4px
  );
  pointer-events: none;
}

/* Cosme hero elements */
/* --- Cosme Hero: コスメパレット風 --- */
/* ヒーロー全体をパレットケースに見立てる */

/* 既存のbubble/blob/deco要素を非表示（CSS::before/afterで全面パレットを描画） */
.hero-bg-cosme .bubble,
.hero-bg-cosme .gradient-blob,
.hero-bg-cosme .deco-circle,
.hero-bg-cosme .deco-square {
  display: none;
}

/* パレットのベース: 全面グリッド */
.hero-bg-cosme::before {
  content: '';
  position: absolute;
  inset: 0;
  /* パレット風グリッドを背景で描画 */
  background:
    /* 仕切り線（縦） */
    linear-gradient(90deg, transparent 24.9%, rgba(180, 140, 120, 0.12) 25%, rgba(180, 140, 120, 0.12) 25.3%, transparent 25.4%),
    linear-gradient(90deg, transparent 49.9%, rgba(180, 140, 120, 0.12) 50%, rgba(180, 140, 120, 0.12) 50.3%, transparent 50.4%),
    linear-gradient(90deg, transparent 74.9%, rgba(180, 140, 120, 0.12) 75%, rgba(180, 140, 120, 0.12) 75.3%, transparent 75.4%),
    /* 仕切り線（横） */
    linear-gradient(180deg, transparent 32.9%, rgba(180, 140, 120, 0.12) 33%, rgba(180, 140, 120, 0.12) 33.4%, transparent 33.5%),
    linear-gradient(180deg, transparent 65.9%, rgba(180, 140, 120, 0.12) 66%, rgba(180, 140, 120, 0.12) 66.4%, transparent 66.5%),
    /* カラーブロック: 上段（ハイライト〜アイシャドウ） */
    linear-gradient(160deg, rgba(245, 213, 200, 0.45), rgba(232, 196, 168, 0.35)) no-repeat 0% 0% / 25% 33%,
    linear-gradient(135deg, rgba(212, 165, 116, 0.4), rgba(201, 155, 109, 0.3)) no-repeat 25% 0% / 25% 33%,
    linear-gradient(145deg, rgba(200, 170, 155, 0.35), rgba(176, 140, 128, 0.25)) no-repeat 50% 0% / 25% 33%,
    linear-gradient(135deg, rgba(232, 160, 180, 0.4), rgba(212, 114, 140, 0.3)) no-repeat 75% 0% / 25% 33%,
    /* カラーブロック: 中段（リップ〜チーク） */
    linear-gradient(140deg, rgba(204, 68, 85, 0.35), rgba(232, 90, 90, 0.25)) no-repeat 0% 33% / 25% 33%,
    linear-gradient(135deg, rgba(224, 112, 112, 0.35), rgba(240, 160, 160, 0.25)) no-repeat 25% 33% / 25% 33%,
    linear-gradient(150deg, rgba(255, 182, 193, 0.4), rgba(255, 154, 162, 0.3)) no-repeat 50% 33% / 25% 33%,
    linear-gradient(135deg, rgba(240, 192, 176, 0.4), rgba(232, 176, 160, 0.3)) no-repeat 75% 33% / 25% 33%,
    /* カラーブロック: 下段（ヌード〜ピーチ） */
    linear-gradient(155deg, rgba(221, 160, 160, 0.3), rgba(200, 136, 136, 0.2)) no-repeat 0% 66% / 25% 34%,
    linear-gradient(135deg, rgba(245, 220, 210, 0.35), rgba(235, 200, 185, 0.25)) no-repeat 25% 66% / 25% 34%,
    linear-gradient(140deg, rgba(255, 230, 220, 0.4), rgba(255, 210, 195, 0.3)) no-repeat 50% 66% / 25% 34%,
    linear-gradient(135deg, rgba(255, 204, 153, 0.3), rgba(255, 185, 140, 0.2)) no-repeat 75% 66% / 25% 34%;
  z-index: 1;
}

/* テキスト周りの可読性: 中央に白いソフトグロー */
.hero-bg-cosme::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse 60% 50% at 50% 50%,
    rgba(255, 250, 248, 0.7) 0%,
    rgba(255, 250, 248, 0.3) 40%,
    transparent 70%
  );
  z-index: 2;
}

/* パレット光沢アニメーション（bubble-0を光沢レイヤーとして再利用） */
[data-theme="cosme"] .hero-bg-cosme .bubble-0 {
  display: block !important;
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  border-radius: 0;
  box-shadow: none;
  background: linear-gradient(
    105deg,
    transparent 0%,
    transparent 40%,
    rgba(255, 255, 255, 0.25) 45%,
    rgba(255, 255, 255, 0.08) 55%,
    transparent 60%,
    transparent 100%
  );
  background-size: 200% 100%;
  animation: palette-shine 6s ease-in-out infinite !important;
  z-index: 4;
  pointer-events: none;
}

@keyframes palette-shine {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.hero-content {
  position: relative;
  z-index: 10;
  text-align: center;
  padding: 8rem 1rem;
}

/* Theme-specific text visibility */
.tagline-gamer,
.title-glitch,
.btn-text-gamer,
.label-gamer,
.title-gamer {
  display: none !important;
}

.tagline-default,
.btn-text-default,
.label-default,
.title-default {
  display: inline !important;
}

[data-theme="gamer"] .tagline-gamer,
[data-theme="gamer"] .btn-text-gamer,
[data-theme="gamer"] .label-gamer,
[data-theme="gamer"] .title-gamer {
  display: inline !important;
}

[data-theme="gamer"] .tagline-default,
[data-theme="gamer"] .btn-text-default,
[data-theme="gamer"] .label-default,
[data-theme="gamer"] .title-default {
  display: none !important;
}

[data-theme="gamer"] .title-glitch {
  display: block !important;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  color: var(--neon-magenta);
  opacity: 0.3;
  transform: translate(7px, 7px);
  pointer-events: none;
}

.hero-tagline {
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  margin-bottom: 1.5rem;
}

[data-theme="business"] .hero-tagline {
  color: var(--accent);
}

[data-theme="gamer"] .hero-tagline {
  color: var(--neon-magenta);
  text-transform: uppercase;
  letter-spacing: 0.3em;
}

[data-theme="cosme"] .hero-tagline {
  color: var(--accent);
}

.hero-title {
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 2rem;
}

@media (min-width: 768px) {
  .hero-title {
    font-size: 3.75rem;
  }
}

@media (min-width: 1024px) {
  .hero-title {
    font-size: 4.5rem;
  }
}

[data-theme="business"] .hero-title {
  color: var(--hero-text);
  font-family: var(--font-heading);
}

[data-theme="business"] .hero-title .accent {
  color: var(--accent);
}

[data-theme="gamer"] .hero-title {
  color: white;
  position: relative;
  text-shadow: 0 0 10px rgba(0, 255, 255, 0.3), 0 0 20px rgba(0, 255, 255, 0.1), 0 0 40px rgba(0, 255, 255, 0.3);
}

[data-theme="gamer"] .hero-title .accent {
  color: var(--neon-cyan);
  text-shadow: 0 0 20px var(--neon-cyan), 0 0 40px var(--neon-cyan);
}

/* Title Lines - for multi-line display */
.title-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.title-line {
  display: block;
}

[data-theme="gamer"] .title-line {
  display: block;
}

[data-theme="business"] .title-line.title-accent {
  color: var(--accent);
}

[data-theme="gamer"] .title-line.title-accent {
  color: var(--neon-cyan);
  text-shadow: 0 0 20px var(--neon-cyan), 0 0 40px var(--neon-cyan), 0 0 60px var(--neon-cyan);
}

[data-theme="cosme"] .title-line.title-accent {
  background: linear-gradient(90deg, #ff6b9d, #ffb347);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Title glitch effect for Gamer */
.title-glitch {
  display: none;
}

[data-theme="gamer"] .title-glitch {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: absolute;
  inset: 0;
  color: var(--neon-magenta);
  opacity: 0.3;
  transform: translate(3px, 3px);
  pointer-events: none;
  z-index: -1;
}

/* title-glitch内のspanを改行させる */
[data-theme="gamer"] .title-glitch span {
  display: block;
}

[data-theme="gamer"] .hero-title .line-break {
  display: block;
}

[data-theme="gamer"] .hero-title .glitch-shadow {
  position: absolute;
  top: 0;
  left: 0;
  color: #ff00ff;
  opacity: 0.3;
  transform: translate(2px, 0);
  pointer-events: none;
}

[data-theme="cosme"] .hero-title {
  color: var(--hero-text);
  font-family: var(--font-heading);
}

[data-theme="cosme"] .hero-title .accent {
  background: linear-gradient(90deg, var(--accent), #ffb347);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-description {
  font-size: 1rem;
  line-height: 1.8;
  margin-bottom: 3rem;
  max-width: 672px;
  margin-left: auto;
  margin-right: auto;
}

@media (min-width: 768px) {
  .hero-description {
    font-size: 1.125rem;
  }
}

[data-theme="business"] .hero-description {
  color: var(--hero-text-secondary);
}

[data-theme="gamer"] .hero-description {
  color: var(--foreground-secondary);
}

[data-theme="cosme"] .hero-description {
  color: var(--hero-text-secondary);
}

.hero-description .highlight,
.hero-description .description-highlight {
  font-weight: 700;
}

[data-theme="business"] .description-highlight {
  color: var(--accent);
}

[data-theme="gamer"] .description-highlight {
  color: var(--neon-cyan);
}

[data-theme="cosme"] .description-highlight {
  color: var(--accent);
}

[data-theme="business"] .hero-description .highlight {
  color: var(--foreground);
}

[data-theme="gamer"] .hero-description .highlight {
  color: var(--neon-cyan);
}

[data-theme="cosme"] .hero-description .highlight {
  color: var(--accent);
}

.hero-buttons,
.hero-cta {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
}

@media (min-width: 640px) {
  .hero-buttons,
  .hero-cta {
    flex-direction: row;
    justify-content: center;
  }
}

.hero-buttons .btn,
.hero-cta .btn {
  padding: 1rem 2rem;
  font-size: 1rem;
}

/* Scroll Indicator */
.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  transition: color var(--transition-base);
}

.scroll-text {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.scroll-arrow {
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-10px);
  }
  60% {
    transform: translateY(-5px);
  }
}

[data-theme="business"] .scroll-indicator {
  color: #6b7280;
}

[data-theme="business"] .scroll-indicator:hover {
  color: var(--accent);
}

[data-theme="gamer"] .scroll-indicator {
  color: var(--neon-cyan);
}

[data-theme="gamer"] .scroll-arrow {
  filter: drop-shadow(0 0 8px var(--neon-cyan));
}

[data-theme="cosme"] .scroll-indicator {
  color: #ff6b9d;
}

/* Hero Background Decorations */
.hero-bg-decoration {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

/* Business: Geometric shapes */
[data-theme="business"] .geo-shape {
  position: absolute;
  border: 2px solid rgba(0, 102, 204, 0.1);
}

[data-theme="business"] .geo-shape.square {
  width: 8rem;
  height: 8rem;
  border-radius: var(--radius-lg);
  animation: float 8s ease-in-out infinite;
}

[data-theme="business"] .geo-shape.circle {
  width: 12rem;
  height: 12rem;
  border-radius: 50%;
  animation: rotate 25s linear infinite;
}

/* Gamer: Grid & Neon lines
   注意: hero用の装飾は .hero-bg-gamer 配下で定義済み（806行〜）
   ここではセクション共通のGamer装飾のみ（重複しない） */

/* Cosme: Bubbles & Soft shapes */
[data-theme="cosme"] .bubble {
  position: absolute;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(255, 182, 193, 0.4), rgba(255, 179, 71, 0.3));
  animation: bubble-float 8s ease-in-out infinite;
}

[data-theme="cosme"] .soft-gradient {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
}

/* ============================================
   Component Styles - Section Headers
============================================ */
.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
}

[data-theme="business"] .section-label {
  color: var(--accent);
}

[data-theme="gamer"] .section-label {
  color: var(--neon-cyan);
  text-transform: uppercase;
  letter-spacing: 0.3em;
}

[data-theme="cosme"] .section-label {
  color: var(--accent);
}

.section-title {
  font-size: 1.875rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
  .section-title {
    font-size: 2.25rem;
  }
}

@media (min-width: 1024px) {
  .section-title {
    font-size: 3rem;
  }
}

[data-theme="business"] .section-title {
  color: var(--foreground);
  font-family: var(--font-heading);
}

[data-theme="gamer"] .section-title {
  color: white;
  position: relative;
  display: inline-block;
}

/* glitch-shadow要素がある場合 */
[data-theme="gamer"] .section-title .glitch-shadow {
  position: absolute;
  top: -12px;
  left: 0;
  color: #ff00ff;
  opacity: 0.3;
  transform: translate(4px, 0);
  pointer-events: none;
  white-space: nowrap;
}

[data-theme="gamer"] .glitch-wrapper {
  position: relative;
  display: inline-block;
}

/* data-text属性による疑似要素でのグリッチ効果 */
[data-theme="gamer"] .glitch-text {
  position: relative;
  display: inline-block;
}

[data-theme="gamer"] .glitch-text[data-text]::after {
  content: attr(data-text);
  position: absolute;
  top: -12px;
  left: 0;
  color: #ff00ff;
  opacity: 0.3;
  transform: translate(3px, 0);
  pointer-events: none;
  white-space: nowrap;
}

[data-theme="cosme"] .section-title {
  color: var(--foreground);
  font-family: var(--font-heading);
}

.section-description {
  font-size: 1rem;
  max-width: 600px;
  margin: 0 auto;
}

@media (min-width: 768px) {
  .section-description {
    font-size: 1.125rem;
  }
}

[data-theme="business"] .section-description {
  color: var(--foreground-secondary);
}

[data-theme="gamer"] .section-description {
  color: var(--foreground-secondary);
}

[data-theme="cosme"] .section-description {
  color: var(--foreground-secondary);
}

/* ============================================
   Services Grid
============================================ */
.services-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .services-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
  }
}

/* Service Card */
.service-card {
  padding: 1.5rem;
  transition: box-shadow 0.4s ease, border-color 0.4s ease;
  position: relative;
  overflow: hidden;
}

@media (min-width: 768px) {
  .service-card {
    padding: 2rem;
  }
}

/* Business theme service card */
[data-theme="business"] .service-card {
  background-color: var(--card);
  border-radius: var(--radius-lg);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  border: 1px solid transparent;
}

[data-theme="business"] .service-card:hover {
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.16);
  border-color: rgba(0, 102, 204, 0.2);
}

/* Gamer theme service card */
[data-theme="gamer"] .service-card {
  background-color: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 0;
}

[data-theme="gamer"] .service-card:hover {
  border-color: rgba(0, 255, 255, 0.5);
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.1);
}

/* Gamer: 左シアン・右マゼンタの縦ライン（h-0→h-fullアニメーション） */
[data-theme="gamer"] .service-decoration {
  position: absolute;
  width: 0.5rem;
  height: 0;
  transition: height 0.3s ease;
}

[data-theme="gamer"] .service-decoration-left {
  top: 0;
  left: 0;
  background: #00ffff;
}

[data-theme="gamer"] .service-decoration-right {
  bottom: 0;
  right: 0;
  background: #ff00ff;
}

[data-theme="gamer"] .service-card:hover .service-decoration {
  height: 100%;
}

/* Cosme theme service card */
[data-theme="cosme"] .service-card {
  background-color: var(--card);
  border-radius: 1.5rem;
  box-shadow: 0 2px 8px rgba(255, 107, 157, 0.08);
  border: 1px solid var(--card-border);
}

[data-theme="cosme"] .service-card:hover {
  box-shadow: 0 12px 32px rgba(255, 107, 157, 0.15);
}

/* Service Icon */
.service-icon {
  width: 3.5rem;
  height: 3.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  transition: all var(--transition-base);
}

.service-icon svg {
  width: 28px;
  height: 28px;
}

[data-theme="business"] .service-icon {
  background-color: var(--accent-light);
  border-radius: var(--radius);
  color: var(--accent);
}

[data-theme="business"] .service-card:hover .service-icon {
  background-color: var(--accent);
  color: white;
}

[data-theme="gamer"] .service-icon {
  background-color: rgba(0, 255, 255, 0.1);
  color: var(--neon-cyan);
  border-radius: 0;
}

[data-theme="gamer"] .service-card:hover .service-icon {
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.5);
}

[data-theme="cosme"] .service-icon {
  background: linear-gradient(135deg, rgba(255, 107, 157, 0.15), rgba(255, 179, 71, 0.15));
  border-radius: var(--radius);
  color: var(--accent);
}

/* Service Title */
.service-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  transition: color var(--transition-base);
}

[data-theme="business"] .service-title { color: var(--foreground); }
[data-theme="business"] .service-card:hover .service-title { color: var(--accent); }
[data-theme="gamer"] .service-title { color: white; }
[data-theme="gamer"] .service-card:hover .service-title { color: var(--neon-cyan); }
[data-theme="cosme"] .service-title { color: var(--foreground); }
[data-theme="cosme"] .service-card:hover .service-title { color: var(--accent); }

/* Service Description */
.service-description {
  font-size: 0.875rem;
  line-height: 1.7;
  margin-bottom: 1rem;
  color: var(--foreground-secondary);
}

/* Service Features (Tags) */
.service-features {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.feature-tag {
  display: inline-block;
  font-size: 0.75rem;
  padding: 0.25rem 0.75rem;
  transition: all var(--transition-base);
}

[data-theme="business"] .feature-tag {
  background-color: var(--background-secondary);
  color: var(--foreground-secondary);
  border-radius: var(--radius);
}

[data-theme="gamer"] .feature-tag {
  background-color: rgba(0, 255, 255, 0.1);
  color: var(--neon-cyan);
  border: 1px solid rgba(0, 255, 255, 0.3);
}

[data-theme="cosme"] .feature-tag {
  background: linear-gradient(135deg, rgba(255, 107, 157, 0.1), rgba(255, 179, 71, 0.1));
  color: var(--accent);
  border-radius: var(--radius-full);
}

/* ============================================
   Component Styles - Cards (Generic)
============================================ */
.card {
  padding: 1.5rem;
  transition: all var(--transition-base);
}

@media (min-width: 768px) {
  .card {
    padding: 2rem;
  }
}

[data-theme="business"] .card {
  background-color: var(--card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid transparent;
}

[data-theme="business"] .card:hover {
  box-shadow: var(--shadow-lg);
  border-color: rgba(0, 102, 204, 0.2);
}

[data-theme="gamer"] .card {
  background-color: var(--card);
  border: 1px solid var(--card-border);
}

[data-theme="gamer"] .card:hover {
  border-color: rgba(0, 255, 255, 0.5);
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.1);
}

[data-theme="cosme"] .card {
  background-color: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--card-border);
}

[data-theme="cosme"] .card:hover {
  box-shadow: var(--shadow-lg);
}

.card-icon {
  width: 3.5rem;
  height: 3.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  transition: all var(--transition-base);
}

[data-theme="business"] .card-icon {
  background-color: var(--accent-light);
  border-radius: var(--radius);
  color: var(--accent);
}

[data-theme="business"] .card:hover .card-icon {
  background-color: var(--accent);
  color: white;
}

[data-theme="gamer"] .card-icon {
  background-color: rgba(0, 255, 255, 0.1);
  color: var(--neon-cyan);
}

[data-theme="gamer"] .card:hover .card-icon {
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.5);
}

[data-theme="cosme"] .card-icon {
  background: linear-gradient(135deg, rgba(255, 107, 157, 0.1), rgba(255, 179, 71, 0.1));
  border-radius: 1rem;
  color: var(--accent);
}

.card-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  transition: color var(--transition-base);
}

[data-theme="business"] .card-title {
  color: var(--foreground);
}

[data-theme="business"] .card:hover .card-title {
  color: var(--accent);
}

[data-theme="gamer"] .card-title {
  color: white;
}

[data-theme="gamer"] .card:hover .card-title {
  color: var(--neon-cyan);
}

[data-theme="cosme"] .card-title {
  color: var(--foreground);
}

[data-theme="cosme"] .card:hover .card-title {
  color: var(--accent);
}

.card-description {
  font-size: 0.875rem;
  line-height: 1.7;
  margin-bottom: 1rem;
}

[data-theme="business"] .card-description {
  color: var(--foreground-secondary);
}

[data-theme="gamer"] .card-description {
  color: var(--foreground-secondary);
}

[data-theme="cosme"] .card-description {
  color: var(--foreground-secondary);
}

/* Tags */
.tag {
  display: inline-block;
  font-size: 0.75rem;
  padding: 0.25rem 0.75rem;
  transition: color var(--transition-base);
}

[data-theme="business"] .tag {
  background-color: var(--background-secondary);
  color: var(--foreground-secondary);
  border-radius: var(--radius);
}

[data-theme="gamer"] .tag {
  background-color: rgba(26, 26, 37, 1);
  color: rgba(0, 255, 255, 0.7);
  border: 1px solid rgba(0, 255, 255, 0.2);
}

[data-theme="cosme"] .tag {
  background-color: var(--background-secondary);
  color: var(--accent);
  border-radius: var(--radius-full);
}

/* ============================================
   Component Styles - Stats
============================================ */
/* HTMLは section.stats（stats-sectionではない） */
.stats-section,
.section.stats {
  padding: 4rem 0;
  position: relative;
  overflow: hidden;
}

@media (min-width: 768px) {
  .stats-section,
  .section.stats {
    padding: 6rem 0;
  }
}

[data-theme="business"] .stats-section,
[data-theme="business"] .section.stats {
  background: linear-gradient(90deg, var(--accent), var(--accent-hover));
}

[data-theme="gamer"] .stats-section,
[data-theme="gamer"] .section.stats {
  background-color: var(--background);
}

[data-theme="cosme"] .stats-section,
[data-theme="cosme"] .section.stats {
  background: linear-gradient(90deg, rgba(255, 107, 157, 0.1), rgba(255, 179, 71, 0.1), rgba(255, 107, 157, 0.1));
}

.stat-card {
  text-align: center;
  padding: 1.5rem;
  position: relative;
}

@media (min-width: 768px) {
  .stat-card {
    padding: 2rem;
  }
}

[data-theme="business"] .stat-card {
  background-color: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

[data-theme="gamer"] .stat-card {
  background-color: var(--card);
  border: 1px solid var(--card-border);
}

[data-theme="cosme"] .stat-card {
  background-color: white;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}

.stat-value {
  font-size: clamp(2.5rem, 6vw, 3.75rem);
  font-weight: 700;
  margin-bottom: 0.5rem;
}

[data-theme="business"] .stat-value {
  color: var(--accent);
}

[data-theme="gamer"] .stat-value {
  color: var(--neon-cyan);
  text-shadow: 0 0 20px rgba(0, 255, 255, 0.5);
}

[data-theme="cosme"] .stat-value {
  background: linear-gradient(90deg, var(--accent), #ffb347);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-label {
  font-size: 0.875rem;
  font-weight: 500;
}

@media (min-width: 768px) {
  .stat-label {
    font-size: 1rem;
  }
}

[data-theme="business"] .stat-label {
  color: var(--foreground-secondary);
}

[data-theme="gamer"] .stat-label {
  color: var(--foreground-secondary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

[data-theme="cosme"] .stat-label {
  color: var(--foreground-secondary);
}

/* Gamer stat corners */
[data-theme="gamer"] .stat-card::before,
[data-theme="gamer"] .stat-card::after,
[data-theme="gamer"] .stat-card .corner-bl,
[data-theme="gamer"] .stat-card .corner-br {
  content: '';
  position: absolute;
  width: 1rem;
  height: 1rem;
  border-width: 2px;
  border-style: solid;
}

[data-theme="gamer"] .stat-card::before {
  top: 0;
  left: 0;
  border-color: var(--neon-cyan) transparent transparent var(--neon-cyan);
}

[data-theme="gamer"] .stat-card::after {
  top: 0;
  right: 0;
  border-color: var(--neon-magenta) var(--neon-magenta) transparent transparent;
}

[data-theme="gamer"] .stat-card .corner-bl {
  bottom: 0;
  left: 0;
  border-color: transparent transparent var(--neon-magenta) var(--neon-magenta);
}

[data-theme="gamer"] .stat-card .corner-br {
  bottom: 0;
  right: 0;
  border-color: transparent var(--neon-cyan) var(--neon-cyan) transparent;
}

/* ============================================
   ブログ図解パーツ
   記事本文中に使うフロー図・構成図・比較・ポイント
============================================ */

/* --- フロー図: ステップを矢印でつなぐ --- */
.npc-flow {
  display: flex;
  align-items: center;
  gap: 0;
  margin: 2rem 0;
  overflow-x: auto;
  padding: 1rem 0;
}

.npc-flow-step {
  background: var(--background-secondary);
  border: 1.5px solid var(--border);
  padding: 0.75rem 1.25rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--foreground);
  text-align: center;
  min-width: 100px;
}

.npc-flow-step.is-accent {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}

[data-theme="gamer"] .npc-flow-step.is-accent {
  color: #0a0a0f;
}

.npc-flow-arrow {
  font-size: 1.2rem;
  color: var(--accent);
  padding: 0 0.5rem;
  flex-shrink: 0;
}

/* --- 構成図: 親子関係のツリー --- */
.npc-structure {
  margin: 2rem 0;
  padding: 1.5rem;
  background: var(--background-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.npc-structure-title {
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--border);
}

.npc-structure-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.npc-structure-list li {
  position: relative;
  padding: 0.4rem 0 0.4rem 1.5rem;
  font-size: 0.9rem;
  color: var(--foreground);
  line-height: 1.6;
}

.npc-structure-list li::before {
  content: '\251C';
  position: absolute;
  left: 0;
  font-family: monospace;
  color: var(--foreground-secondary);
}

.npc-structure-list li:last-child::before {
  content: '\2514';
}

.npc-structure-list .npc-child {
  list-style: none;
  padding: 0;
  margin: 0 0 0 1.5rem;
}

.npc-structure-list .npc-child li::before {
  content: '\251C';
}

.npc-structure-list .npc-child li:last-child::before {
  content: '\2514';
}

/* --- 比較ボックス: 2〜3列の比較 --- */
.npc-compare {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
  margin: 2rem 0;
}

.npc-compare-item {
  background: var(--background-secondary);
  border: 1.5px solid var(--border);
  padding: 1.25rem;
  border-radius: var(--radius);
}

.npc-compare-item.is-recommended {
  border-color: var(--accent);
}

[data-theme="gamer"] .npc-compare-item.is-recommended {
  border-color: var(--neon-cyan);
}

.npc-compare-label {
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

.npc-compare-item.is-recommended .npc-compare-label::after {
  content: ' \2605';
}

.npc-compare-body {
  font-size: 0.85rem;
  color: var(--foreground);
  line-height: 1.7;
}

.npc-compare-body ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.npc-compare-body li {
  padding: 0.2rem 0;
}

/* --- ポイントボックス: 番号付き要点 --- */
.npc-points {
  margin: 2rem 0;
  counter-reset: npc-point;
}

.npc-point {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
}

.npc-point:last-child {
  border-bottom: none;
}

.npc-point::before {
  counter-increment: npc-point;
  content: counter(npc-point);
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--accent);
  flex-shrink: 0;
  width: 2rem;
  text-align: center;
  line-height: 1;
  padding-top: 0.15rem;
}

.npc-point-body {
  font-size: 0.9rem;
  line-height: 1.7;
  color: var(--foreground);
}

.npc-point-body strong {
  color: var(--accent);
}

[data-theme="gamer"] .npc-point-body strong {
  color: var(--neon-cyan);
}

/* --- KPIカード: データ指標の強調表示 --- */
.npc-kpi-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin: 1.5rem 0;
}

.npc-kpi-card {
  background: var(--background-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.2rem 1.5rem;
}

[data-theme="gamer"] .npc-kpi-card {
  background: #0a0a0f;
}

.npc-kpi-label {
  font-size: 0.75rem;
  color: var(--foreground-secondary);
  letter-spacing: 0.05em;
  margin-bottom: 0.4rem;
}

.npc-kpi-value {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
  color: var(--foreground);
}

.npc-kpi-change {
  font-size: 0.8rem;
  font-weight: 600;
  margin-top: 0.3rem;
  color: var(--accent);
}

/* --- テーブル: npc-table --- */
.npc-table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
  font-size: 0.9rem;
  line-height: 1.7;
}

.npc-table thead th {
  background: var(--accent);
  color: white;
  font-family: var(--font-heading);
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 2px solid var(--accent);
}

[data-theme="gamer"] .npc-table thead th {
  background: var(--neon-cyan);
  color: #0a0a0f;
}

[data-theme="cosme"] .npc-table thead th {
  background: linear-gradient(90deg, var(--accent), #ffb347);
}

.npc-table tbody td {
  padding: 0.75rem 1rem;
  color: var(--foreground);
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

.npc-table tbody tr:last-child td {
  border-bottom: none;
}

.npc-table tbody tr:nth-child(even) {
  background: var(--background-secondary);
}

.npc-table td.is-accent,
.npc-table th.is-accent {
  color: var(--accent);
  font-weight: 700;
}

.npc-table.is-2col th:first-child,
.npc-table.is-2col td:first-child { width: 45%; }

.npc-table.is-3col th,
.npc-table.is-3col td { width: 33.33%; }

.npc-table.is-4col th,
.npc-table.is-4col td { width: 25%; }

/* --- 図解レスポンシブ --- */
@media (max-width: 640px) {
  .npc-flow {
    flex-direction: column;
    align-items: stretch;
  }

  .npc-flow-step {
    min-width: auto;
  }

  .npc-flow-arrow {
    text-align: center;
    transform: rotate(90deg);
    padding: 0.25rem 0;
  }

  .npc-compare {
    grid-template-columns: 1fr;
  }

  .npc-kpi-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .npc-kpi-card {
    padding: 1rem 1.2rem;
  }

  .npc-kpi-value {
    font-size: 1.6rem;
  }

  .npc-table {
    font-size: 0.8rem;
  }

  .npc-table thead th,
  .npc-table tbody td {
    padding: 0.5rem 0.6rem;
  }

  .npc-table.is-2col th:first-child,
  .npc-table.is-2col td:first-child,
  .npc-table.is-3col th,
  .npc-table.is-3col td,
  .npc-table.is-4col th,
  .npc-table.is-4col td {
    width: auto;
  }
}

/* ============================================
   Component Styles - Profile
============================================ */
.profile-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  max-width: 56rem;
  margin: 0 auto;
}

/* 画像なし: 1カラム中央寄せ */
.profile-grid-single {
  grid-template-columns: 1fr;
}

.profile-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.profile-item {
  display: flex;
  gap: 1.5rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--border);
}

.profile-item:last-child {
  border-bottom: none;
}

.profile-item dt {
  min-width: 6rem;
  font-weight: 700;
  font-size: 0.875rem;
  color: var(--foreground);
}

[data-theme="gamer"] .profile-item dt {
  color: var(--neon-cyan);
}

.profile-item dd {
  font-size: 0.875rem;
  color: var(--foreground-secondary);
  line-height: 1.6;
}

.profile-item dd a {
  color: var(--accent);
  transition: opacity var(--transition-base);
}

.profile-item dd a:hover {
  opacity: 0.7;
}

[data-theme="gamer"] .profile-item dd a {
  color: var(--neon-cyan);
}

/* ============================================
   Comments Section
============================================ */
.comments-section,
.blog-comments {
  padding: 2rem 0 4rem;
  background-color: var(--background-secondary);
}

.blog-comments .container {
  max-width: 48rem;
}

.comments-title {
  font-family: var(--font-heading);
  font-size: clamp(1.2rem, 2.5vw, 1.6rem);
  color: var(--foreground);
  margin-bottom: 2rem;
}

/* コメントリスト */
.commentlist,
.comment-list {
  list-style: none;
  padding: 0;
  margin: 0 0 3rem;
}

.commentlist > .comment {
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  transition: border-color 0.3s;
}

.commentlist > .comment:hover {
  border-color: var(--accent);
}

[data-theme="gamer"] .commentlist > .comment {
  background: #0a0a0f;
}

[data-theme="gamer"] .commentlist > .comment:hover {
  border-color: var(--neon-cyan);
}

/* 返信（ネスト） */
.commentlist .children {
  list-style: none;
  padding: 0.75rem 0 0 1.5rem;
  margin: 1rem 0 0;
  border-left: 3px solid var(--accent);
}

[data-theme="gamer"] .commentlist .children {
  border-left-color: var(--neon-cyan);
}

.commentlist .children .comment {
  padding: 1.25rem;
  margin-bottom: 0.75rem;
  background: var(--background-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  position: relative;
}

.commentlist .children .comment::before {
  content: "\21B3 返信";
  display: inline-block;
  font-size: 0.7rem;
  color: var(--accent);
  background: var(--background);
  border: 1px solid var(--accent);
  padding: 0.1rem 0.5rem;
  border-radius: 3px;
  margin-bottom: 0.75rem;
}

[data-theme="gamer"] .commentlist .children .comment::before {
  color: var(--neon-cyan);
  border-color: var(--neon-cyan);
}

.comment-body .says {
  display: none;
}

/* コメントメタ */
.comment-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.comment-meta .avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  flex-shrink: 0;
}

[data-theme="gamer"] .comment-meta .avatar {
  border-color: var(--neon-cyan);
  border-radius: 0;
}

[data-theme="cosme"] .comment-meta .avatar {
  border-color: var(--accent);
}

.comment-author.vcard {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.comment-author .fn {
  font-weight: 700;
  color: var(--foreground);
  font-size: 0.95rem;
}

.comment-author .fn a {
  color: var(--foreground);
  text-decoration: none;
}

.comment-author .fn a:hover {
  color: var(--accent);
}

/* 投稿者バッジ */
.bypostauthor > .comment-body .comment-author .fn::after {
  content: "Author";
  font-size: 0.65rem;
  font-weight: 400;
  color: white;
  background: var(--accent);
  padding: 0.1rem 0.4rem;
  border-radius: 3px;
  margin-left: 0.5rem;
  vertical-align: middle;
}

[data-theme="gamer"] .bypostauthor > .comment-body .comment-author .fn::after {
  background: var(--neon-cyan);
  color: #0a0a0f;
}

.comment-metadata {
  margin-left: auto;
  flex-shrink: 0;
}

.comment-metadata a {
  font-size: 0.75rem;
  color: var(--foreground-secondary);
  text-decoration: none;
}

.comment-metadata a:hover {
  color: var(--accent);
}

/* コメント本文 */
.comment-content {
  color: var(--foreground);
  font-size: 0.95rem;
  line-height: 1.8;
}

.comment-content p {
  margin: 0 0 0.5rem;
}

/* 返信リンク */
.reply a {
  display: inline-block;
  margin-top: 0.75rem;
  font-size: 0.8rem;
  color: var(--accent);
  text-decoration: none;
  border: 1px solid var(--accent);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius);
  transition: background 0.3s, color 0.3s;
}

.reply a:hover {
  background: var(--accent);
  color: white;
}

[data-theme="gamer"] .reply a {
  color: var(--neon-cyan);
  border-color: var(--neon-cyan);
}

[data-theme="gamer"] .reply a:hover {
  background: var(--neon-cyan);
  color: #0a0a0f;
}

/* コメントフォーム */
.comment-respond {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}

.comment .comment-respond {
  margin-top: 1.5rem;
  padding: 1.25rem;
  background: var(--background-secondary);
  border: 1px dashed var(--accent);
  border-radius: var(--radius);
}

.comment-reply-title {
  font-family: var(--font-heading);
  font-size: clamp(1rem, 2vw, 1.3rem);
  color: var(--foreground);
  margin-bottom: 1.5rem;
}

.comment-reply-title small {
  margin-left: 0.75rem;
}

.comment-reply-title small a {
  font-size: 0.8rem;
  color: var(--foreground-secondary);
  text-decoration: none;
  border: 1px solid var(--border);
  padding: 0.15rem 0.5rem;
  border-radius: 3px;
  transition: color 0.2s, border-color 0.2s;
}

.comment-reply-title small a:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.comment-form label {
  display: block;
  font-weight: 500;
  font-size: 0.85rem;
  color: var(--foreground-secondary);
  margin-bottom: 0.4rem;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--background-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--foreground);
  font-family: var(--font-body);
  font-size: 0.95rem;
  transition: border-color 0.3s, box-shadow 0.3s;
  box-sizing: border-box;
}

.comment-form input[type="text"]:focus,
.comment-form input[type="email"]:focus,
.comment-form input[type="url"]:focus,
.comment-form textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.15);
}

[data-theme="gamer"] .comment-form input:focus,
[data-theme="gamer"] .comment-form textarea:focus {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 0 3px rgba(0, 255, 255, 0.15);
}

[data-theme="cosme"] .comment-form input:focus,
[data-theme="cosme"] .comment-form textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255, 107, 157, 0.15);
}

[data-theme="gamer"] .comment-form input,
[data-theme="gamer"] .comment-form textarea {
  background: #0a0a0f;
}

.comment-form textarea {
  min-height: 150px;
  resize: vertical;
}

.comment-form p {
  margin-bottom: 1.25rem;
}

.comment-form .logged-in-as {
  font-size: 0.8rem;
  color: var(--foreground-secondary);
}

.comment-form .logged-in-as a {
  color: var(--accent);
  text-decoration: none;
}

.comment-form .form-submit {
  margin-top: 0.5rem;
  display: flex;
  justify-content: center;
}

.comment-form .submit {
  padding: 0.75rem 2.5rem;
  background: var(--accent);
  color: white;
  font-weight: 700;
  font-size: 0.9rem;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background 0.3s, transform 0.2s;
}

.comment-form .submit:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
}

[data-theme="gamer"] .comment-form .submit {
  background: var(--neon-cyan);
  color: #0a0a0f;
  border-radius: 0;
}

[data-theme="gamer"] .comment-form .submit:hover {
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.5);
}

[data-theme="cosme"] .comment-form .submit {
  background: linear-gradient(90deg, var(--accent), #ffb347);
  border-radius: var(--radius-full);
}

.no-comments {
  color: var(--foreground-secondary);
  font-style: italic;
  padding: 1.5rem 0;
}

/* ============================================
   Fixed Page（固定ページ: プラポリ・特商法等）
============================================ */
.page-content {
  padding-top: 8rem;
  padding-bottom: 4rem;
  min-height: 100vh;
}

.page-header {
  text-align: center;
  margin-bottom: 3rem;
}

.page-title {
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  font-weight: 700;
  color: var(--foreground);
}

.page-body {
  max-width: 48rem;
  margin: 0 auto;
}

.page-body h2 {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 700;
  margin: 2.5rem 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--accent);
  color: var(--foreground);
}

[data-theme="gamer"] .page-body h2 {
  border-bottom-color: var(--neon-cyan);
}

.page-body h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 2rem 0 0.75rem;
  color: var(--foreground);
}

.page-body p {
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
  line-height: 1.9;
  color: var(--foreground);
}

.page-body a {
  color: var(--accent);
  text-decoration: underline;
}

[data-theme="gamer"] .page-body a {
  color: var(--neon-cyan);
}

.page-body ul,
.page-body ol {
  padding-left: 1.5rem;
  margin-bottom: 1.5rem;
}

.page-body ul {
  list-style: disc;
}

.page-body ol {
  list-style: decimal;
}

.page-body li {
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
  line-height: 1.8;
}

.page-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.5rem 0;
}

.page-body th,
.page-body td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
  text-align: left;
  font-size: 0.9rem;
}

.page-body th {
  font-weight: 700;
  color: var(--foreground);
  min-width: 8rem;
}

.page-body td {
  color: var(--foreground-secondary);
}

/* ============================================
   Archive Page（汎用）
============================================ */
.archive-page {
  padding-top: 8rem;
  padding-bottom: 4rem;
  min-height: 100vh;
}

.archive-header {
  text-align: center;
  margin-bottom: 3rem;
}

.archive-title {
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  font-weight: 700;
  color: var(--foreground);
  margin-bottom: 1rem;
}

.archive-description {
  color: var(--foreground-secondary);
  max-width: 600px;
  margin: 0 auto;
}

.archive-posts {
  padding-bottom: 4rem;
}

/* pagination（汎用） */
.pagination {
  margin-top: 3rem;
  text-align: center;
}

.pagination .page-numbers {
  display: inline-block;
  padding: 0.5rem 1rem;
  margin: 0 0.25rem;
  font-size: 0.875rem;
  color: var(--foreground-secondary);
  text-decoration: none;
  transition: all 0.3s ease;
  border-radius: var(--radius);
}

.pagination .page-numbers.current,
.pagination .page-numbers:hover {
  background-color: var(--accent);
  color: white;
}

[data-theme="gamer"] .pagination .page-numbers.current,
[data-theme="gamer"] .pagination .page-numbers:hover {
  background-color: var(--neon-cyan);
  color: #0a0a0f;
}

[data-theme="cosme"] .pagination .page-numbers.current,
[data-theme="cosme"] .pagination .page-numbers:hover {
  background: linear-gradient(90deg, var(--accent), #ffb347);
  color: white;
  border-radius: var(--radius-full);
}

.no-posts {
  text-align: center;
  padding: 4rem 0;
  color: var(--foreground-secondary);
}

/* ============================================
   Blog Archive Page
============================================ */
.blog-archive {
  padding-top: 8rem;
  padding-bottom: 4rem;
  min-height: 100vh;
}

.blog-archive .section-header {
  margin-bottom: 3rem;
}

.blog-archive-categories {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  margin-bottom: 3rem;
}

.blog-archive-categories .feature-tag {
  text-decoration: none;
}

.blog-archive-categories .cat-count {
  opacity: 0.6;
  margin-left: 0.25rem;
}

.blog-readmore {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--accent);
  margin-top: 1rem;
  transition: gap 0.3s ease;
}

.blog-readmore svg {
  width: 14px;
  height: 14px;
}

.blog-card:hover .blog-readmore {
  gap: 0.75rem;
}

[data-theme="gamer"] .blog-readmore {
  color: var(--neon-cyan);
}

[data-theme="cosme"] .blog-readmore {
  color: var(--accent);
}

.blog-card-link {
  display: block;
  text-decoration: none;
  color: inherit;
  height: 100%;
}

.blog-pagination {
  margin-top: 3rem;
  text-align: center;
}

.blog-pagination .page-numbers {
  display: inline-block;
  padding: 0.5rem 1rem;
  margin: 0 0.25rem;
  font-size: 0.875rem;
  color: var(--foreground-secondary);
  text-decoration: none;
  transition: all 0.3s ease;
  border-radius: var(--radius);
}

.blog-pagination .page-numbers.current,
.blog-pagination .page-numbers:hover {
  background-color: var(--accent);
  color: white;
}

[data-theme="gamer"] .blog-pagination .page-numbers.current,
[data-theme="gamer"] .blog-pagination .page-numbers:hover {
  background-color: var(--neon-cyan);
  color: #0a0a0f;
}

[data-theme="cosme"] .blog-pagination .page-numbers.current,
[data-theme="cosme"] .blog-pagination .page-numbers:hover {
  background: linear-gradient(90deg, var(--accent), #ffb347);
  color: white;
  border-radius: var(--radius-full);
}

.blog-empty {
  text-align: center;
  padding: 4rem 0;
}

/* ============================================
   Component Styles - Footer
============================================ */
.site-footer {
  padding: 4rem 0 8rem;
  position: relative;
  overflow: hidden;
}

[data-theme="business"] .site-footer {
  background-color: #1a1a1a;
  color: white;
}

[data-theme="gamer"] .site-footer {
  background-color: #050510;
  color: var(--foreground);
}

/* Gamer Footer: グリッド背景 + 上部ネオンライン */
.footer-bg-decoration {
  display: none;
}

[data-theme="gamer"] .footer-bg-decoration {
  display: block;
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

[data-theme="gamer"] .footer-bg-decoration .gamer-grid {
  position: absolute;
  inset: 0;
  opacity: 0.05;
  background-image:
    linear-gradient(to right, #00ffff 1px, transparent 1px),
    linear-gradient(to bottom, #00ffff 1px, transparent 1px);
  background-size: 40px 40px;
}

[data-theme="gamer"] .footer-bg-decoration .gamer-line-top {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0, 255, 255, 0.6), transparent);
}

[data-theme="cosme"] .site-footer {
  background-color: #4a3f3f;
  color: white;
}

.footer-brand {
  margin-bottom: 1.5rem;
}

/* シンプルフッター: 中央揃えレイアウト */
.footer-brand-center {
  text-align: center;
  margin-bottom: 2rem;
}

.footer-brand-center .footer-tagline {
  margin-top: 0.5rem;
}

.footer-nav-inline {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-nav-inline a {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.7);
  transition: color var(--transition-base);
}

.footer-nav-inline a:hover {
  color: var(--accent);
}

[data-theme="gamer"] .footer-nav-inline {
  border-bottom-color: rgba(0, 255, 255, 0.15);
}

[data-theme="gamer"] .footer-nav-inline a {
  color: var(--foreground-secondary);
}

[data-theme="gamer"] .footer-nav-inline a:hover {
  color: var(--neon-cyan);
}

.footer-contact-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-logo {
  font-family: 'Unbounded', var(--font-heading);
  font-size: 1.2rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
  display: inline-block;
}

.footer-logo .logo-accent {
  color: var(--accent);
}

[data-theme="business"] .footer-logo {
  color: white;
}

[data-theme="gamer"] .footer-logo {
  color: var(--neon-cyan);
}

[data-theme="cosme"] .footer-logo {
  color: white;
}

.footer-tagline {
  font-size: 0.875rem;
  line-height: 1.7;
}

[data-theme="business"] .footer-tagline {
  color: rgba(255, 255, 255, 0.7);
}

[data-theme="gamer"] .footer-tagline {
  color: var(--foreground-secondary);
}

[data-theme="cosme"] .footer-tagline {
  color: rgba(255, 255, 255, 0.7);
}

.footer-nav-title {
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 1rem;
}

[data-theme="business"] .footer-nav-title {
  color: white;
}

[data-theme="gamer"] .footer-nav-title {
  color: var(--neon-cyan);
}

[data-theme="cosme"] .footer-nav-title {
  color: white;
}

.footer-nav-link {
  display: block;
  font-size: 0.875rem;
  padding: 0.25rem 0;
  transition: color var(--transition-base);
}

[data-theme="business"] .footer-nav-link {
  color: rgba(255, 255, 255, 0.6);
}

[data-theme="business"] .footer-nav-link:hover {
  color: white;
}

[data-theme="gamer"] .footer-nav-link {
  color: var(--foreground-secondary);
}

[data-theme="gamer"] .footer-nav-link:hover {
  color: var(--neon-cyan);
}

[data-theme="cosme"] .footer-nav-link {
  color: rgba(255, 255, 255, 0.7);
}

[data-theme="cosme"] .footer-nav-link:hover {
  color: white;
}

/* Social links */
.social-links {
  display: flex;
  gap: 0.75rem;
}

.social-link {
  width: 2.5rem;
  height: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
}

[data-theme="business"] .social-link {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius);
  color: white;
}

[data-theme="business"] .social-link:hover {
  background-color: var(--accent);
}

[data-theme="gamer"] .social-link {
  border: 1px solid var(--card-border);
  color: var(--foreground-secondary);
}

[data-theme="gamer"] .social-link:hover {
  border-color: var(--neon-cyan);
  color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
}

[data-theme="cosme"] .social-link {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-full);
  color: white;
}

[data-theme="cosme"] .social-link:hover {
  background-color: var(--accent);
}

.footer-bottom {
  padding-top: 2rem;
  margin-top: 2rem;
  text-align: center;
}

[data-theme="business"] .footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

[data-theme="gamer"] .footer-bottom {
  border-top: 1px solid var(--card-border);
}

[data-theme="cosme"] .footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.legal-links {
  display: flex;
  gap: 1.5rem;
}

.legal-link {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
  transition: color var(--transition-base);
}

.legal-link:hover {
  color: var(--accent);
}

[data-theme="gamer"] .legal-link {
  color: var(--foreground-secondary);
}

[data-theme="gamer"] .legal-link:hover {
  color: var(--neon-cyan);
}

.copyright {
  font-size: 0.75rem;
  margin-top: 0.75rem;
}

[data-theme="business"] .copyright {
  color: rgba(255, 255, 255, 0.5);
}

[data-theme="gamer"] .copyright {
  color: var(--foreground-secondary);
}

[data-theme="cosme"] .copyright {
  color: rgba(255, 255, 255, 0.5);
}

/* Back to top — チャットボタンと同じデザイン */
.back-to-top {
  position: fixed;
  bottom: 2.5rem;
  left: 1.5rem;
  z-index: 50;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  background: var(--background);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.back-to-top:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(0, 0, 0, 0.15);
  background: var(--accent);
  color: white;
}

[data-theme="gamer"] .back-to-top {
  border-color: var(--neon-cyan);
  background: var(--background);
  color: var(--neon-cyan);
}

[data-theme="gamer"] .back-to-top:hover {
  background: var(--neon-cyan);
  color: #0a0a0f;
  box-shadow: 0 6px 28px rgba(0, 0, 0, 0.4);
}

[data-theme="cosme"] .back-to-top {
  border-color: var(--accent);
  background: var(--background);
  color: var(--accent);
}

[data-theme="cosme"] .back-to-top:hover {
  background: var(--accent);
  color: white;
}

/* ============================================
   Theme Switcher
============================================ */
.theme-switcher {
  position: fixed;
  bottom: 2.5rem;
  left: 50%;
  z-index: 1000;
  display: flex !important;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  backdrop-filter: blur(10px);
  /* Default style (fallback) */
  background-color: rgba(255, 255, 255, 0.9);
  border-radius: 0.75rem;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
  border: 1px solid #e8e8e8;
  /* Entry animation initial state */
  transform: translateX(-50%) translateY(100px);
  opacity: 0;
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.5s ease;
}

.theme-switcher.animate-in {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

[data-theme="business"] .theme-switcher {
  background-color: rgba(255, 255, 255, 0.9);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}

[data-theme="gamer"] .theme-switcher {
  background-color: rgba(10, 10, 15, 0.9);
  border: 1px solid rgba(0, 255, 255, 0.3);
  border-radius: 0;
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.2);
}

[data-theme="cosme"] .theme-switcher {
  background-color: rgba(255, 255, 255, 0.9);
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}

.theme-switcher-label {
  font-size: 0.75rem;
  font-weight: 500;
  padding: 0 0.75rem;
  display: none;
}

@media (min-width: 640px) {
  .theme-switcher-label {
    display: block;
  }
}

[data-theme="business"] .theme-switcher-label {
  color: var(--foreground-secondary);
}

[data-theme="gamer"] .theme-switcher-label {
  color: var(--foreground-secondary);
}

[data-theme="cosme"] .theme-switcher-label {
  color: var(--foreground-secondary);
}

.theme-switcher-divider {
  width: 1px;
  height: 1.5rem;
  display: none;
}

@media (min-width: 640px) {
  .theme-switcher-divider {
    display: block;
  }
}

[data-theme="business"] .theme-switcher-divider {
  background-color: var(--border);
}

[data-theme="gamer"] .theme-switcher-divider {
  background-color: var(--card-border);
}

[data-theme="cosme"] .theme-switcher-divider {
  background-color: var(--border);
}

.theme-btn {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 700;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: all var(--transition-base);
  position: relative;
  color: #5a5a5a;
  border-radius: 0.375rem;
}

.theme-btn:hover {
  color: #0066cc;
  background-color: #e6f0fa;
}

.theme-btn.active {
  color: white;
  background-color: #0066cc;
}

[data-theme="business"] .theme-btn:not(.active) {
  color: var(--foreground-secondary);
}

[data-theme="business"] .theme-btn:not(.active):hover {
  color: var(--accent);
  background-color: var(--accent-light);
}

[data-theme="business"] .theme-btn.active {
  background-color: var(--accent);
  border-radius: var(--radius);
}

[data-theme="gamer"] .theme-btn:not(.active) {
  color: var(--foreground-secondary);
}

[data-theme="gamer"] .theme-btn {
  border-radius: 0;
}

[data-theme="gamer"] .theme-btn:not(.active):hover {
  color: var(--neon-cyan);
  background-color: rgba(0, 255, 255, 0.1);
}

[data-theme="gamer"] .theme-btn.active {
  background-color: var(--neon-cyan);
  color: #0a0a0f;
  border-radius: 0;
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.5);
}

[data-theme="cosme"] .theme-btn:not(.active) {
  color: var(--foreground-secondary);
}

[data-theme="cosme"] .theme-btn:not(.active):hover {
  color: var(--accent);
  background-color: var(--accent-light);
}

[data-theme="cosme"] .theme-btn.active {
  background: linear-gradient(90deg, var(--accent), #ffb347);
  border-radius: var(--radius-full);
}

/* Theme Label Display */
.theme-label-display {
  position: fixed;
  bottom: 0.75rem;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  z-index: 49;
  text-align: center;
  opacity: 0;
  transition: all 0.5s ease;
}

.theme-label-display.animate-in {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.theme-description {
  font-size: 0.75rem;
  font-weight: 500;
  white-space: nowrap;
  transition: all 0.3s ease;
}

.theme-description.fade-out {
  opacity: 0;
  transform: translateY(-10px);
}

.theme-description.fade-in {
  opacity: 0;
  transform: translateY(10px);
  animation: fade-in-description 0.3s ease forwards;
}

@keyframes fade-in-description {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.theme-description.theme-business {
  color: var(--accent);
}

.theme-description.theme-gamer {
  color: var(--neon-cyan);
  text-shadow: 0 0 10px var(--neon-cyan);
}

.theme-description.theme-cosme {
  color: #ff6b9d;
}

/* ============================================
   Animations
============================================ */
@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(180deg); }
}

@keyframes rotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes grid-move {
  0% { background-position: 0 0; }
  100% { background-position: 50px 50px; }
}

@keyframes bubble-float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  25% { transform: translateY(-15px) rotate(5deg); }
  50% { transform: translateY(-25px) rotate(0deg); }
  75% { transform: translateY(-15px) rotate(-5deg); }
}

@keyframes glitch {
  0%, 90%, 100% {
    transform: translate(0);
  }
  92% { transform: translate(-2px, 2px); }
  94% { transform: translate(2px, -2px); }
  96% { transform: translate(-1px, 1px); }
  98% { transform: translate(1px, -1px); }
}

/* Gamerテーマ用グリッチアニメーション（text-shadow付き） */
@keyframes gamer-glitch {
  0%, 90%, 100% { transform: translate(0); text-shadow: none; }
  92% { transform: translate(-2px, 2px); text-shadow: 2px 0 #ff00ff, -2px 0 #00ffff; }
  94% { transform: translate(2px, -2px); text-shadow: -2px 0 #ff00ff, 2px 0 #00ffff; }
  96% { transform: translate(-1px, 1px); text-shadow: 1px 0 #ff00ff, -1px 0 #00ffff; }
  98% { transform: translate(1px, -1px); text-shadow: -1px 0 #ff00ff, 1px 0 #00ffff; }
}

/* Gamerテーマ: glitch-textクラスにグリッチアニメーション適用 */
[data-theme="gamer"] .glitch-text {
  animation: gamer-glitch 3s infinite;
  display: inline-block;
}

/* Gamerテーマ: ヒーロータイトル全体もグリッチ */
[data-theme="gamer"] .hero-title .title-wrapper {
  animation: gamer-glitch 3s infinite;
}

@keyframes neon-flicker {
  0%, 19%, 21%, 23%, 25%, 54%, 56%, 100% {
    text-shadow:
      0 0 4px var(--neon-cyan),
      0 0 11px var(--neon-cyan),
      0 0 19px var(--neon-cyan),
      0 0 40px var(--neon-cyan);
    opacity: 1;
  }
  20%, 24%, 55% {
    text-shadow: none;
    opacity: 0.8;
  }
}

@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ============================================
   data-aos スクロールアニメーション
   IntersectionObserverで .aos-animate が付与される
============================================ */
[data-aos] {
  opacity: 0;
  transition-property: opacity, transform;
  transition-duration: 0.8s;
  transition-timing-function: cubic-bezier(0.25, 0.1, 0.25, 1);
}

[data-aos].aos-animate {
  opacity: 1;
}

[data-aos="fade-up"] {
  transform: translateY(30px);
}

[data-aos="fade-up"].aos-animate {
  transform: translateY(0);
}

[data-aos="fade-right"] {
  transform: translateX(-30px);
}

[data-aos="fade-right"].aos-animate {
  transform: translateX(0);
}

[data-aos="fade-left"] {
  transform: translateX(30px);
}

[data-aos="fade-left"].aos-animate {
  transform: translateX(0);
}

/* Animation utilities */
.animate-fade-in-up {
  animation: fade-in-up 0.6s ease forwards;
}

/* ============================================
   Section-Specific Grids
============================================ */

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem;
}

@media (min-width: 768px) {
  .stats-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.stat-item {
  text-align: center;
  padding: 1.5rem;
  position: relative;
}

[data-theme="business"] .stat-item {
  background-color: var(--card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

[data-theme="gamer"] .stat-item {
  background-color: var(--card);
  border: 1px solid var(--card-border);
}

[data-theme="cosme"] .stat-item {
  background-color: var(--card);
  border-radius: 1.5rem;
  box-shadow: var(--shadow-md);
}

.stat-value {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 0.125rem;
}

@media (min-width: 768px) {
  .stat-value {
    font-size: 3.75rem;
  }
}

@media (min-width: 1024px) {
  .stat-value {
    font-size: 4.5rem;
  }
}

.stat-number {
  display: inline;
}

.stat-suffix {
  font-size: 1.5rem;
  font-weight: 600;
}

[data-theme="business"] .stat-value { color: var(--accent); }
[data-theme="gamer"] .stat-value {
  color: var(--neon-cyan);
  text-shadow: 0 0 10px var(--neon-cyan), 0 0 20px var(--neon-cyan), 0 0 40px var(--neon-cyan);
  animation: neon-flicker 4s infinite;
}
[data-theme="cosme"] .stat-value {
  background: linear-gradient(90deg, #ff6b9d, #ffb347);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.stat-label {
  font-size: 0.875rem;
  color: var(--foreground-secondary);
}

/* Stats decoration (Gamer) */
.stat-decoration {
  display: none;
}

[data-theme="gamer"] .stat-decoration {
  display: block;
}

/* Gamer stat corners: TL/BR=シアン、TR/BL=マゼンタ */
.stat-corner {
  position: absolute;
  width: 1rem;
  height: 1rem;
  border-style: solid;
}

.stat-corner-tl { top: 0; left: 0; border-width: 2px 0 0 2px; border-color: var(--neon-cyan); }
.stat-corner-tr { top: 0; right: 0; border-width: 2px 2px 0 0; border-color: #ff00ff; }
.stat-corner-bl { bottom: 0; left: 0; border-width: 0 0 2px 2px; border-color: #ff00ff; }
.stat-corner-br { bottom: 0; right: 0; border-width: 0 2px 2px 0; border-color: var(--neon-cyan); }

/* Stats section background */
.stats-pattern {
  display: none;
}

[data-theme="business"] .stats-pattern {
  display: block;
  position: absolute;
  inset: 0;
  opacity: 0.1;
  background-image:
    linear-gradient(45deg, white 25%, transparent 25%),
    linear-gradient(-45deg, white 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, white 75%),
    linear-gradient(-45deg, transparent 75%, white 75%);
  background-size: 20px 20px;
}

[data-theme="gamer"] .stats-pattern {
  display: block;
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle, rgba(0, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 20px 20px;
  pointer-events: none;
}

.stats-line {
  display: none;
}

[data-theme="gamer"] .stats-line {
  display: block;
  position: absolute;
  left: 0;
  right: 0;
  height: 1px;
}

[data-theme="gamer"] .stats-line-top {
  top: 0;
  background: linear-gradient(90deg, transparent, rgba(0, 255, 255, 0.5), transparent);
}

[data-theme="gamer"] .stats-line-bottom {
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 0, 255, 0.5), transparent);
}

.stats-header {
  text-align: center;
  margin-bottom: 3rem;
}

[data-theme="gamer"] .stats-header {
  display: none;
}

.stats-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--foreground);
  margin-bottom: 0.5rem;
  font-family: var(--font-heading);
}

[data-theme="business"] .stats-title {
  color: white;
}

.stats-subtitle {
  color: var(--foreground-secondary);
}

[data-theme="business"] .stats-subtitle {
  color: rgba(255, 255, 255, 0.8);
}

/* Works Grid（スライダー非対応の場合のフォールバック） */
.works-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 2rem;
}

@media (min-width: 768px) {
  .works-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .works-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* Works Slider Container */
.works-slider {
  position: relative;
  /* overflow: hidden はtrack側に移動（矢印が見えるように） */
}

.works-track-wrapper {
  overflow: hidden;
}

/* Works Track: flex横並び（スライダー用） */
.works-track {
  display: flex;
  gap: 1.5rem;
  padding: 2rem 0;
  transition: transform 0.8s cubic-bezier(0.25, 0.1, 0.25, 1);
}

.works-track .work-card {
  flex-shrink: 0;
  width: 100%;
}

@media (min-width: 768px) {
  .works-track .work-card {
    width: calc(33.333% - 1rem);
  }
}

/* Slider Navigation Buttons */
/* スライダー矢印: 四角ボタン、常に表示 */
.slider-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 3rem;
  height: 3rem;
  border-radius: 0;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
}

.slider-nav-prev {
  left: 0.5rem;
}

.slider-nav-next {
  right: 0.5rem;
}

@media (min-width: 1024px) {
  .slider-nav-prev {
    left: -3.5rem;
  }

  .slider-nav-next {
    right: -3.5rem;
  }
}

/* Business テーマのナビボタン */
[data-theme="business"] .slider-nav {
  background-color: #ffffff;
  color: var(--accent);
  box-shadow: var(--shadow-md);
}

[data-theme="business"] .slider-nav:hover {
  background-color: var(--accent);
  color: #ffffff;
}

/* Gamer テーマのナビボタン */
[data-theme="gamer"] .slider-nav {
  background-color: rgba(10, 10, 15, 0.8);
  color: var(--neon-cyan);
  border: 1px solid var(--neon-cyan);
}

[data-theme="gamer"] .slider-nav:hover {
  background-color: var(--neon-cyan);
  color: #0a0a0f;
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.5);
}

/* Cosme テーマのナビボタン */
[data-theme="cosme"] .slider-nav {
  background-color: #ffffff;
  color: var(--accent);
  box-shadow: var(--shadow-md);
}

[data-theme="cosme"] .slider-nav:hover {
  background: linear-gradient(90deg, var(--accent), #ffb347);
  color: #ffffff;
}

/* Slider Dots */
.slider-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 2rem;
}

.slider-dot {
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  transition: all var(--transition-base);
  padding: 0;
}

[data-theme="business"] .slider-dot {
  background-color: var(--border);
}

[data-theme="business"] .slider-dot.active {
  background-color: var(--accent);
}

[data-theme="gamer"] .slider-dot {
  background-color: var(--card-border);
}

[data-theme="gamer"] .slider-dot.active {
  background-color: var(--neon-cyan);
  box-shadow: 0 0 8px var(--neon-cyan);
}

[data-theme="cosme"] .slider-dot {
  background-color: var(--border);
}

[data-theme="cosme"] .slider-dot.active {
  background: linear-gradient(90deg, var(--accent), #ffb347);
}

/* Work Card */
.work-card {
  position: relative;
  overflow: hidden;
  transition: all var(--transition-base);
}

[data-theme="business"] .work-card {
  background-color: var(--card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

[data-theme="business"] .work-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

[data-theme="gamer"] .work-card {
  background-color: var(--card);
  border: 1px solid var(--card-border);
}

[data-theme="gamer"] .work-card:hover {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 30px rgba(0, 255, 255, 0.2);
}

[data-theme="cosme"] .work-card {
  background-color: var(--card);
  border-radius: 1.5rem;
  box-shadow: var(--shadow-lg);
}

[data-theme="cosme"] .work-card:hover {
  box-shadow: 0 20px 40px rgba(255, 107, 157, 0.15);
}

.work-image {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/10;
}

.work-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.work-card:hover .work-image img {
  transform: scale(1.05);
}

.work-content {
  padding: 1.5rem;
}

.work-category {
  font-size: 0.75rem;
  margin-bottom: 0.5rem;
}

[data-theme="business"] .work-category { color: var(--accent); }
[data-theme="gamer"] .work-category { color: var(--neon-magenta); text-transform: uppercase; }
[data-theme="cosme"] .work-category { color: var(--accent); }

.work-title {
  font-size: 1.125rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--foreground);
}

.work-description {
  font-size: 0.875rem;
  color: var(--foreground-secondary);
  line-height: 1.6;
}

.work-tech,
.work-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.tech-tag,
.work-tag {
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
}

[data-theme="business"] .tech-tag,
[data-theme="business"] .work-tag {
  background-color: var(--background-secondary);
  color: var(--foreground-secondary);
  border-radius: var(--radius);
}

[data-theme="gamer"] .tech-tag,
[data-theme="gamer"] .work-tag {
  background-color: rgba(0, 255, 255, 0.1);
  color: var(--neon-cyan);
  border: 1px solid rgba(0, 255, 255, 0.3);
}

[data-theme="cosme"] .tech-tag,
[data-theme="cosme"] .work-tag {
  background: linear-gradient(135deg, rgba(255, 107, 157, 0.1), rgba(255, 179, 71, 0.1));
  color: var(--accent);
  border-radius: var(--radius-full);
}

/* Work Image Placeholder & Overlay */
.work-placeholder {
  width: 100%;
  height: 100%;
  /* --work-color はインラインスタイルで.work-imageに設定、子要素に継承 */
  background-color: var(--work-color, var(--background-secondary));
  background-image: linear-gradient(135deg, rgba(255,255,255,0.15) 0%, rgba(0,0,0,0.3) 100%);
}

/* テーマ別フォールバック（--work-colorが未設定の場合のみ効く） */
[data-theme="gamer"] .work-placeholder {
  border: 1px solid var(--card-border);
}

/* カード全体リンク */
.work-card-link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.work-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-base);
}

.work-card:hover .work-overlay {
  opacity: 1;
}

.work-link-text {
  color: white;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

[data-theme="gamer"] .work-overlay {
  background-color: rgba(0, 0, 0, 0.85);
}

[data-theme="gamer"] .work-link-text {
  color: var(--neon-cyan);
}

.work-image .work-category {
  position: absolute;
  top: 1rem;
  left: 1rem;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
  z-index: 1;
}

[data-theme="business"] .work-image .work-category {
  background-color: white;
  color: var(--accent);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

[data-theme="gamer"] .work-image .work-category {
  background-color: rgba(0, 0, 0, 0.8);
  color: var(--neon-magenta);
  border: 1px solid var(--neon-magenta);
}

[data-theme="cosme"] .work-image .work-category {
  background-color: white;
  color: var(--accent);
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-sm);
}

/* Process Grid */
.process-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 2rem;
}

@media (min-width: 768px) {
  .process-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
  }
}

@media (min-width: 1024px) {
  .process-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.process-card {
  position: relative;
  padding: 2rem;
  transition: all var(--transition-base);
}

[data-theme="business"] .process-card {
  background-color: var(--card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

[data-theme="gamer"] .process-card {
  background-color: var(--card);
  border: 1px solid var(--card-border);
}

[data-theme="cosme"] .process-card {
  background-color: var(--card);
  border-radius: 1.5rem;
  box-shadow: var(--shadow-lg);
}

.process-number {
  font-size: 3rem;
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1;
}

[data-theme="business"] .process-number { color: var(--accent); opacity: 0.3; }
[data-theme="gamer"] .process-number { color: var(--neon-cyan); opacity: 0.5; }
[data-theme="cosme"] .process-number { color: var(--accent); opacity: 0.3; }

.process-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--foreground);
}

.process-description {
  font-size: 0.875rem;
  color: var(--foreground-secondary);
  line-height: 1.7;
}

/* Process Timeline - Next.js同期版 */
.process-timeline-wrapper {
  position: relative;
  max-width: 56rem;
  margin: 0 auto;
}

/* Connecting Line */
.process-line {
  display: none;
  position: absolute;
  left: 2rem;
  top: 0;
  bottom: 0;
  width: 1px;
}

@media (min-width: 768px) {
  .process-line {
    display: block;
    left: 50%;
    transform: translateX(-50%);
  }
}

[data-theme="business"] .process-line {
  background-color: #e8e8e8;
}

[data-theme="gamer"] .process-line {
  background: linear-gradient(to bottom, var(--neon-cyan), var(--neon-magenta), var(--neon-cyan));
}

[data-theme="cosme"] .process-line {
  background: linear-gradient(to bottom, #ff6b9d, #ffb347);
}

.process-steps {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

@media (min-width: 768px) {
  .process-steps {
    gap: 3rem;
  }
}

/* スマホ: 縦積み（アイコン→カード） */
.process-step {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
}

@media (min-width: 768px) {
  .process-step {
    flex-direction: row;
    align-items: flex-start;
    gap: 3rem;
  }

  .process-step.step-left {
    flex-direction: row;
  }

  .process-step.step-right {
    flex-direction: row-reverse;
  }
}

/* Step Card */
.step-card {
  flex: 1;
  padding: 2.5rem 2.5rem;
  transition: all var(--transition-base);
}

@media (max-width: 767px) {
  .step-card {
    padding: 1.5rem;
    text-align: center;
    width: 100%;
  }
}

@media (min-width: 768px) {
  .step-left .step-card {
    text-align: right;
  }

  .step-right .step-card {
    text-align: left;
  }
}

[data-theme="business"] .step-card {
  background-color: #f8f9fa;
  border-radius: var(--radius-lg);
}

[data-theme="business"] .step-card:hover {
  box-shadow: var(--shadow-lg);
}

[data-theme="gamer"] .step-card {
  background-color: #12121a;
  border: 1px solid #2a2a3a;
}

[data-theme="gamer"] .step-card:hover {
  border-color: rgba(0, 255, 255, 0.5);
}

[data-theme="cosme"] .step-card {
  background-color: white;
  border-radius: 1.5rem;
  box-shadow: var(--shadow-lg);
}

[data-theme="cosme"] .step-card:hover {
  box-shadow: var(--shadow-xl);
}

/* Duration Badge */
.step-duration {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 500;
  padding: 0.25rem 0.75rem;
  margin-bottom: 1rem;
}

[data-theme="business"] .step-duration {
  background-color: rgba(0, 102, 204, 0.1);
  color: var(--accent);
  border-radius: var(--radius);
}

[data-theme="gamer"] .step-duration {
  background-color: rgba(0, 255, 255, 0.1);
  color: var(--neon-cyan);
}

[data-theme="cosme"] .step-duration {
  background-color: rgba(255, 107, 157, 0.1);
  color: #ff6b9d;
  border-radius: var(--radius-full);
}

.step-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--foreground);
}

.step-description {
  font-size: 0.875rem;
  line-height: 1.7;
  color: var(--foreground-secondary);
}

/* Center Icon */
.step-icon-wrapper {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 10;
  order: -1; /* スマホではアイコンを上部に */
}

@media (min-width: 768px) {
  .step-icon-wrapper {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    order: 0;
  }
}

.step-icon {
  width: 3.5rem;
  height: 3.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

[data-theme="business"] .step-icon {
  background-color: var(--accent);
  color: white;
  border-radius: 50%;
  box-shadow: var(--shadow-lg);
}

[data-theme="gamer"] .step-icon {
  background-color: rgba(0, 0, 0, 0.5);
  color: var(--neon-cyan);
  border: 2px solid var(--neon-cyan);
  border-radius: 0;
  box-shadow: 0 0 20px rgba(0, 255, 255, 0.3);
}

[data-theme="cosme"] .step-icon {
  background: linear-gradient(135deg, #ff6b9d, #ffb347);
  color: white;
  border-radius: 50%;
  box-shadow: var(--shadow-lg);
}

.step-number {
  font-size: 1rem;
  font-weight: 700;
  margin-top: 0.5rem;
}

[data-theme="business"] .step-number { color: var(--accent); }
[data-theme="gamer"] .step-number { color: var(--neon-cyan); }
[data-theme="cosme"] .step-number { color: #ff6b9d; }

/* Spacer */
.step-spacer {
  display: none;
}

@media (min-width: 768px) {
  .step-spacer {
    display: block;
    flex: 1;
  }
}

/* Process Background */
.process-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.process-grid-pattern {
  display: none;
}

[data-theme="gamer"] .process-grid-pattern {
  display: block;
  position: absolute;
  inset: 0;
  opacity: 0.05;
  background-image:
    linear-gradient(to right, var(--neon-cyan) 1px, transparent 1px),
    linear-gradient(to bottom, var(--neon-cyan) 1px, transparent 1px);
  background-size: 60px 60px;
}

/* Legacy Process Timeline Grid (fallback) */
.process-timeline-grid {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 2rem;
}

@media (min-width: 768px) {
  .process-timeline-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .process-timeline-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.step-marker {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

/* 重複定義を削除（3304行目で定義済み） */

/* 重複定義を削除（3275行目付近で定義済み） */

.step-title {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--foreground);
  margin-bottom: 0.5rem;
}

.step-description {
  font-size: 0.875rem;
  color: var(--foreground-secondary);
  line-height: 1.6;
}

.step-connector {
  display: none; /* Hidden in grid layout */
}

/* Blog: すべての記事を見るボタン */
.blog-more {
  text-align: center;
  margin-top: 3rem;
}

/* Blog Grid */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr));
  gap: 2rem;
}

.blog-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  overflow: hidden;
}

.blog-card:hover {
  transform: translateY(-4px);
}

[data-theme="business"] .blog-card {
  background-color: var(--card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

[data-theme="business"] .blog-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

[data-theme="gamer"] .blog-card {
  background-color: var(--card);
  border: 1px solid var(--card-border);
}

[data-theme="gamer"] .blog-card:hover {
  border-color: var(--neon-cyan);
}

[data-theme="cosme"] .blog-card {
  background-color: var(--card);
  border-radius: 1.5rem;
  box-shadow: var(--shadow-lg);
}

.blog-image {
  position: relative;
  aspect-ratio: 17/9;
  overflow: hidden;
}

.blog-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.blog-card:hover .blog-image img {
  transform: scale(1.05);
}

/* --- テーマカラーオーバーレイ（一覧+詳細共通） --- */
.blog-image::after,
.blog-featured-image::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

[data-theme="business"] .blog-image::after,
[data-theme="business"] .blog-featured-image::after {
  background: linear-gradient(135deg, rgba(0, 102, 204, 0.15), rgba(0, 77, 153, 0.25));
}

[data-theme="gamer"] .blog-image::after,
[data-theme="gamer"] .blog-featured-image::after {
  background: linear-gradient(135deg, rgba(0, 255, 255, 0.1), rgba(255, 0, 255, 0.15));
}

[data-theme="cosme"] .blog-image::after,
[data-theme="cosme"] .blog-featured-image::after {
  background: linear-gradient(135deg, rgba(255, 107, 157, 0.12), rgba(255, 179, 71, 0.18));
}

/* hover時にオーバーレイが消える（一覧カードのみ） */
.blog-card:hover .blog-image::after {
  opacity: 0;
}

.blog-image-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

[data-theme="business"] .blog-image-placeholder {
  background: linear-gradient(135deg, #e8f0fe 0%, #c9daf8 100%);
}

[data-theme="gamer"] .blog-image-placeholder {
  background: linear-gradient(135deg, #0a0a0f 0%, #1a1a2e 100%);
}

[data-theme="cosme"] .blog-image-placeholder {
  background: linear-gradient(135deg, #fff5f8 0%, #ffe4ec 100%);
}

.blog-category {
  position: absolute;
  top: 1rem;
  left: 1rem;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
  z-index: 5;
}

[data-theme="business"] .blog-category {
  background-color: white;
  color: var(--accent);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

[data-theme="gamer"] .blog-category {
  background-color: rgba(0, 0, 0, 0.8);
  color: var(--neon-cyan);
  border: 1px solid var(--neon-cyan);
}

[data-theme="cosme"] .blog-category {
  background-color: white;
  color: var(--accent);
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-sm);
}

.blog-content {
  padding: 1.5rem;
}

.blog-date {
  font-size: 0.75rem;
  color: var(--foreground-secondary);
  margin-bottom: 0.5rem;
}

.blog-title {
  font-size: 1.125rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--foreground);
  line-height: 1.5;
}

.blog-excerpt {
  font-size: 0.875rem;
  color: var(--foreground-secondary);
  line-height: 1.6;
}

/* About Section */
[data-theme="gamer"] .about {
  background-color: #12121a;
  position: relative;
  overflow: hidden;
}

[data-theme="gamer"] .process {
  background-color: #0a0a0f;
}

[data-theme="gamer"] .about::before,
[data-theme="gamer"] .about::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
}

[data-theme="gamer"] .about::before {
  width: 24rem;
  height: 24rem;
  top: 5rem;
  left: 5rem;
  background: rgba(0, 255, 255, 0.04);
}

[data-theme="gamer"] .about::after {
  width: 24rem;
  height: 24rem;
  bottom: 5rem;
  right: 5rem;
  background: rgba(255, 0, 255, 0.04);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  align-items: center;
}

@media (min-width: 1024px) {
  .about-grid {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
  }
}

.about-content {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.about-label {
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 0.25rem;
}

[data-theme="gamer"] .about-label {
  color: var(--neon-cyan);
  text-transform: uppercase;
}

.about-title {
  font-size: clamp(1.75rem, 6vw, 3rem);
  font-weight: 700;
  color: var(--foreground);
  margin-bottom: 0.5rem;
}

.about-text {
  color: var(--foreground-secondary);
  line-height: 1.8;
}

.about-text p {
  margin-bottom: 1rem;
}

.about-text .text-accent {
  color: var(--accent);
}

[data-theme="gamer"] .about-text .text-accent {
  color: var(--neon-cyan);
}

.skills-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--foreground-secondary);
  margin-bottom: 0.75rem;
}

[data-theme="gamer"] .skills-label {
  color: var(--neon-cyan);
  text-transform: uppercase;
  letter-spacing: 0.3em;
}

.skills-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.about-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1.5rem;
}

/* About Values Grid */
.about-values {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.value-card {
  padding: 1.5rem;
  transition: all var(--transition-base);
}

[data-theme="business"] .value-card {
  background-color: var(--card);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

[data-theme="business"] .value-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

[data-theme="gamer"] .value-card {
  background-color: #0a0a0f;
  border: 1px solid var(--card-border);
}

[data-theme="gamer"] .value-card:hover {
  border-color: rgba(0, 255, 255, 0.4);
  box-shadow: 0 0 12px rgba(0, 255, 255, 0.08);
}

[data-theme="cosme"] .value-card {
  background-color: var(--card);
  border-radius: 1.5rem;
  box-shadow: var(--shadow-lg);
}

.value-icon {
  width: 3rem;
  height: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  border-radius: var(--radius);
}

[data-theme="business"] .value-icon {
  background-color: var(--accent-light);
  color: var(--accent);
}

[data-theme="gamer"] .value-icon {
  background-color: rgba(0, 255, 255, 0.1);
  color: var(--neon-cyan);
}

[data-theme="cosme"] .value-icon {
  background: linear-gradient(135deg, rgba(255, 107, 157, 0.1), rgba(255, 179, 71, 0.1));
  color: var(--accent);
}

.value-title {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--foreground);
  margin-bottom: 0.5rem;
}

.value-description {
  font-size: 0.875rem;
  color: var(--foreground-secondary);
  line-height: 1.6;
}

.about-image {
  position: relative;
}

.about-image img {
  width: 100%;
  border-radius: var(--radius-lg);
}

[data-theme="gamer"] .about-image img {
  border-radius: 0;
  border: 1px solid var(--card-border);
}

[data-theme="cosme"] .about-image img {
  border-radius: 2rem;
}

.about-text h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--foreground);
}

.about-text p {
  color: var(--foreground-secondary);
  line-height: 1.8;
  margin-bottom: 1rem;
}

.about-skills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.skill-tag {
  font-size: 0.875rem;
  padding: 0.5rem 1rem;
  transition: all var(--transition-base);
}

[data-theme="business"] .skill-tag {
  background-color: var(--accent-light);
  color: var(--accent);
  border-radius: var(--radius);
}

[data-theme="gamer"] .skill-tag {
  background-color: rgba(0, 255, 255, 0.05);
  color: var(--foreground-secondary);
  border: 1px solid var(--card-border);
  padding: 0.2rem 1rem;
  transition: none;
}

[data-theme="gamer"] .skill-tag:hover {
  color: var(--neon-cyan);
  border-color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
}

[data-theme="cosme"] .skill-tag {
  background: linear-gradient(135deg, rgba(255, 107, 157, 0.1), rgba(255, 179, 71, 0.1));
  color: var(--accent);
  border-radius: var(--radius-full);
}

/* Contact Section */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
}

@media (min-width: 1024px) {
  .contact-grid {
    grid-template-columns: 2fr 3fr;
    gap: 4rem;
  }
}

.contact-content {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
}

@media (min-width: 1024px) {
  .contact-content {
    grid-template-columns: 1fr 1.5fr;
    gap: 4rem;
  }
}

.contact-info {
  display: flex;
  flex-direction: column;
}

.contact-info .section-header-left {
  text-align: center;
  margin-bottom: 1.5rem;
}

@media (min-width: 1024px) {
  .contact-info .section-header-left {
    text-align: left;
  }
}

@media (max-width: 1023px) {
  .contact-description {
    text-align: center;
  }
}

.contact-description {
  color: var(--foreground-secondary);
  line-height: 1.8;
  margin-bottom: 2rem;
}

.contact-info h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--foreground);
}

.contact-info p {
  color: var(--foreground-secondary);
  line-height: 1.8;
  margin-bottom: 1.5rem;
}

.contact-methods {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-method {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem;
  transition: all var(--transition-base);
}

[data-theme="business"] .contact-method {
  background-color: var(--card);
  border-radius: var(--radius-lg);
}

[data-theme="business"] .contact-method:hover {
  box-shadow: var(--shadow-md);
}

[data-theme="gamer"] .contact-method {
  background-color: #0a0a0f;
  border: 1px solid var(--card-border);
}

[data-theme="gamer"] .contact-method:hover {
  border-color: var(--neon-cyan);
}

[data-theme="cosme"] .contact-method {
  background-color: var(--card);
  border-radius: 1rem;
}

.method-icon,
.contact-method-icon {
  width: 2.5rem;
  height: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
}

[data-theme="business"] .contact-method-icon,
[data-theme="business"] .method-icon {
  background-color: var(--accent-light);
  color: var(--accent);
}

[data-theme="gamer"] .contact-method-icon,
[data-theme="gamer"] .method-icon {
  background-color: rgba(0, 255, 255, 0.1);
  color: var(--neon-cyan);
  border: 1px solid rgba(0, 255, 255, 0.3);
}

[data-theme="cosme"] .contact-method-icon,
[data-theme="cosme"] .method-icon {
  background: linear-gradient(135deg, rgba(255, 107, 157, 0.1), rgba(255, 179, 71, 0.1));
  color: var(--accent);
  border-radius: 0.75rem;
}

.method-content {
  flex: 1;
}

.method-label {
  display: block;
  font-size: 0.75rem;
  color: var(--foreground-secondary);
  margin-bottom: 0.25rem;
}

.method-value {
  font-weight: 500;
  color: var(--foreground);
}

a.method-value {
  transition: color var(--transition-base);
}

a.method-value:hover {
  color: var(--accent);
}

[data-theme="gamer"] .method-value {
  color: white;
}

[data-theme="gamer"] a.method-value:hover {
  color: var(--neon-cyan);
}

/* CF7フォームをテーマデザインに統合 */
.form-card .wpcf7-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-card .wpcf7-form p {
  margin: 0;
}

.form-card .wpcf7-form .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

@media (max-width: 767px) {
  .form-card .wpcf7-form .form-row {
    grid-template-columns: 1fr;
  }
}

.form-card .wpcf7-form .form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-card .wpcf7-form input[type="text"],
.form-card .wpcf7-form input[type="email"],
.form-card .wpcf7-form select,
.form-card .wpcf7-form textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--background-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--foreground);
  font-family: var(--font-body);
  font-size: 0.95rem;
  transition: border-color 0.3s, box-shadow 0.3s;
  box-sizing: border-box;
  -webkit-appearance: none;
  appearance: none;
}

.form-card .wpcf7-form input:focus,
.form-card .wpcf7-form select:focus,
.form-card .wpcf7-form textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.15);
}

[data-theme="gamer"] .form-card .wpcf7-form input,
[data-theme="gamer"] .form-card .wpcf7-form select,
[data-theme="gamer"] .form-card .wpcf7-form textarea {
  background: #0a0a0f;
}

[data-theme="gamer"] .form-card .wpcf7-form input:focus,
[data-theme="gamer"] .form-card .wpcf7-form select:focus,
[data-theme="gamer"] .form-card .wpcf7-form textarea:focus {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 0 3px rgba(0, 255, 255, 0.15);
}

[data-theme="cosme"] .form-card .wpcf7-form input:focus,
[data-theme="cosme"] .form-card .wpcf7-form select:focus,
[data-theme="cosme"] .form-card .wpcf7-form textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255, 107, 157, 0.15);
}

.form-card .wpcf7-form textarea {
  min-height: 150px;
  resize: vertical;
}

/* CF7 送信ボタン */
.form-card .wpcf7-form input[type="submit"] {
  width: 100%;
  padding: 1.2rem 1.25rem;
  font-size: 1.2rem;
  font-weight: 700;
  background: var(--accent);
  color: white;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background 0.3s, transform 0.2s;
}

.form-card .wpcf7-form input[type="submit"]:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
}

[data-theme="gamer"] .form-card .wpcf7-form input[type="submit"] {
  background: var(--neon-cyan);
  color: #0a0a0f;
  border-radius: 0;
}

[data-theme="gamer"] .form-card .wpcf7-form input[type="submit"]:hover {
  box-shadow: 0 0 30px rgba(0, 255, 255, 0.5);
}

[data-theme="cosme"] .form-card .wpcf7-form input[type="submit"] {
  background: linear-gradient(90deg, var(--accent), #ffb347);
  border-radius: var(--radius-full);
}

/* CF7 バリデーション */
.form-card .wpcf7-not-valid-tip {
  color: #ff4444;
  font-size: 0.75rem;
  margin-top: 0.25rem;
}

.form-card .wpcf7-response-output {
  margin-top: 1rem;
  padding: 1rem;
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  font-size: 0.85rem;
  text-align: center;
}

/* Turnstile CAPTCHA */
.form-card .wpcf7-turnstile {
  display: flex;
  justify-content: center;
  margin-bottom: 0.5rem;
}

/* Contact Form - form-cardが唯一のカード枠 */
.form-card {
  width: 100%;
  padding: 2rem;
  transition: all var(--transition-base);
}

[data-theme="business"] .form-card {
  background-color: var(--card);
  border-radius: var(--radius-lg);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

[data-theme="gamer"] .form-card {
  background-color: #0a0a0f;
  border: 1px solid var(--card-border);
}

[data-theme="cosme"] .form-card {
  background-color: var(--card);
  border-radius: 2rem;
  box-shadow: var(--shadow-lg);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .form-row {
    grid-template-columns: 1fr 1fr;
  }
}

.form-select {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  border: 1px solid var(--border);
  background-color: var(--background);
  color: var(--foreground);
  transition: all var(--transition-base);
}

[data-theme="business"] .form-select {
  border-radius: var(--radius);
}

[data-theme="gamer"] .form-select {
  border-color: var(--card-border);
  background-color: rgba(0, 0, 0, 0.3);
}

[data-theme="cosme"] .form-select {
  border-radius: var(--radius-lg);
}

.required {
  color: #ef4444;
}

.btn-full {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

/* Contact Form - 装飾は.form-cardが担当。.contact-formは装飾なし */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* 送信ボタン */
.btn-submit {
  padding: 1.2rem 1.25rem;
  font-size: 1.2rem;
}

.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: var(--foreground);
}

.form-input,
.form-textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  border: 1px solid var(--border);
  background-color: var(--background);
  color: var(--foreground);
  transition: all var(--transition-base);
}

[data-theme="business"] .form-input,
[data-theme="business"] .form-textarea {
  border-radius: var(--radius);
}

[data-theme="business"] .form-input:focus,
[data-theme="business"] .form-textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
  outline: none;
}

[data-theme="gamer"] .form-input,
[data-theme="gamer"] .form-textarea {
  border-color: var(--card-border);
  background-color: rgba(0, 0, 0, 0.3);
}

[data-theme="gamer"] .form-input:focus,
[data-theme="gamer"] .form-textarea:focus {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.3);
  outline: none;
}

[data-theme="cosme"] .form-input,
[data-theme="cosme"] .form-textarea {
  border-radius: var(--radius-lg);
  border-color: var(--card-border);
}

[data-theme="cosme"] .form-input:focus,
[data-theme="cosme"] .form-textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255, 107, 157, 0.1);
  outline: none;
}

.form-textarea {
  min-height: 150px;
  resize: vertical;
}

.form-submit {
  width: 100%;
}

.animate-fade-in {
  animation: fade-in 0.6s ease forwards;
}

.animation-delay-100 { animation-delay: 0.1s; }
.animation-delay-200 { animation-delay: 0.2s; }
.animation-delay-300 { animation-delay: 0.3s; }
.animation-delay-400 { animation-delay: 0.4s; }
.animation-delay-500 { animation-delay: 0.5s; }

/* Gamer glitch effect */
[data-theme="gamer"] .glitch {
  animation: glitch 3s infinite;
}

[data-theme="gamer"] .neon-flicker {
  animation: neon-flicker 4s infinite;
}

/* ============================================
   Form Styles
============================================ */
.form-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
}

[data-theme="business"] .form-label {
  color: var(--foreground);
}

[data-theme="gamer"] .form-label {
  color: var(--foreground-secondary);
}

[data-theme="cosme"] .form-label {
  color: var(--foreground);
}

.form-label .required {
  color: #ef4444;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  transition: all var(--transition-base);
  outline: none;
}

[data-theme="business"] .form-input,
[data-theme="business"] .form-select,
[data-theme="business"] .form-textarea {
  background-color: var(--background-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--foreground);
}

[data-theme="business"] .form-input:focus,
[data-theme="business"] .form-select:focus,
[data-theme="business"] .form-textarea:focus {
  border-color: var(--accent);
}

[data-theme="gamer"] .form-input,
[data-theme="gamer"] .form-select,
[data-theme="gamer"] .form-textarea {
  background-color: var(--card);
  border: 1px solid var(--card-border);
  color: white;
}

[data-theme="gamer"] .form-input:focus,
[data-theme="gamer"] .form-select:focus,
[data-theme="gamer"] .form-textarea:focus {
  border-color: var(--neon-cyan);
}

[data-theme="cosme"] .form-input,
[data-theme="cosme"] .form-select,
[data-theme="cosme"] .form-textarea {
  background-color: var(--background-secondary);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--foreground);
}

[data-theme="cosme"] .form-input:focus,
[data-theme="cosme"] .form-select:focus,
[data-theme="cosme"] .form-textarea:focus {
  border-color: var(--accent);
}

.form-textarea {
  resize: vertical;
  min-height: 150px;
}

/* ============================================
   Responsive Visibility
============================================ */
.hidden { display: none; }
.block { display: block; }

@media (min-width: 640px) {
  .sm\:block { display: block; }
  .sm\:hidden { display: none; }
}

@media (min-width: 768px) {
  .md\:block { display: block; }
  .md\:hidden { display: none; }
  .md\:flex { display: flex; }
}

@media (min-width: 1024px) {
  .lg\:block { display: block; }
  .lg\:hidden { display: none; }
  .lg\:flex { display: flex; }
}

/* Screen reader only */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ============================================
   Theme-specific text visibility
============================================ */
/* Default: hide gamer-specific text */
.title-gamer,
.label-gamer,
.btn-text-gamer,
.logo-text-shadow,
.footer-logo-shadow {
  display: none;
}

.title-default,
.label-default,
.btn-text-default {
  display: inline;
}

/* Gamer theme: show gamer text, hide default */
[data-theme="gamer"] .title-gamer,
[data-theme="gamer"] .label-gamer,
[data-theme="gamer"] .btn-text-gamer {
  display: inline;
}

[data-theme="gamer"] .title-default,
[data-theme="gamer"] .label-default,
[data-theme="gamer"] .btn-text-default {
  display: none;
}

[data-theme="gamer"] .logo-text-shadow,
[data-theme="gamer"] .footer-logo-shadow {
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  color: var(--neon-magenta);
  opacity: 0.5;
  transform: translate(2px, 2px);
  pointer-events: none;
}

/* Logo text styling */
.site-logo {
  position: relative;
}

.logo-text {
  position: relative;
  z-index: 1;
}

/* Footer logo shadow */
.footer-logo {
  position: relative;
}

/* Theme label display - スイッチャーの上に配置 */
/* 注: 表示/非表示は上部の .theme-label-display ルールで制御 */

/* Theme button labels - アクティブなボタンのみ名称表示 */
.theme-btn .theme-label {
  display: none;
  font-size: 0.625rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-left: 0.25rem;
}

.theme-btn.active .theme-label {
  display: inline;
}

/* Theme buttons container */
.theme-buttons {
  display: flex;
  gap: 0.25rem;
}

/* ============================================
   Tailwind-like Utility Classes
============================================ */

/* Display */
.flex { display: flex; }
.inline-flex { display: inline-flex; }
.grid { display: grid; }
.hidden { display: none; }
.block { display: block; }
.inline-block { display: inline-block; }

/* Flex Direction */
.flex-col { flex-direction: column; }
.flex-row { flex-direction: row; }

/* Flex Wrap */
.flex-wrap { flex-wrap: wrap; }
.flex-nowrap { flex-wrap: nowrap; }

/* Justify Content */
.justify-start { justify-content: flex-start; }
.justify-end { justify-content: flex-end; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-around { justify-content: space-around; }

/* Align Items */
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }
.items-center { align-items: center; }
.items-stretch { align-items: stretch; }

/* Flex */
.flex-1 { flex: 1 1 0%; }
.flex-auto { flex: 1 1 auto; }
.flex-shrink-0 { flex-shrink: 0; }

/* Gap */
.gap-0 { gap: 0; }
.gap-1 { gap: 0.25rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-5 { gap: 1.25rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }
.gap-10 { gap: 2.5rem; }
.gap-12 { gap: 3rem; }
.gap-16 { gap: 4rem; }

/* Grid */
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-cols-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }

/* Padding */
.p-0 { padding: 0; }
.p-1 { padding: 0.25rem; }
.p-2 { padding: 0.5rem; }
.p-3 { padding: 0.75rem; }
.p-4 { padding: 1rem; }
.p-5 { padding: 1.25rem; }
.p-6 { padding: 1.5rem; }
.p-8 { padding: 2rem; }
.p-10 { padding: 2.5rem; }
.p-12 { padding: 3rem; }
.p-16 { padding: 4rem; }
.p-20 { padding: 5rem; }
.p-24 { padding: 6rem; }

.px-0 { padding-left: 0; padding-right: 0; }
.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-5 { padding-left: 1.25rem; padding-right: 1.25rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.px-8 { padding-left: 2rem; padding-right: 2rem; }

.py-0 { padding-top: 0; padding-bottom: 0; }
.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-6 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }
.py-20 { padding-top: 5rem; padding-bottom: 5rem; }
.py-24 { padding-top: 6rem; padding-bottom: 6rem; }

.pt-4 { padding-top: 1rem; }
.pt-8 { padding-top: 2rem; }
.pt-12 { padding-top: 3rem; }
.pt-16 { padding-top: 4rem; }
.pt-20 { padding-top: 5rem; }
.pb-4 { padding-bottom: 1rem; }
.pb-8 { padding-bottom: 2rem; }
.pb-12 { padding-bottom: 3rem; }
.pb-16 { padding-bottom: 4rem; }
.pb-20 { padding-bottom: 5rem; }

/* Margin */
.m-0 { margin: 0; }
.m-auto { margin: auto; }
.mx-auto { margin-left: auto; margin-right: auto; }
.my-auto { margin-top: auto; margin-bottom: auto; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 0.75rem; }
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-10 { margin-bottom: 2.5rem; }
.mb-12 { margin-bottom: 3rem; }
.mb-16 { margin-bottom: 4rem; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-4 { margin-top: 1rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-auto { margin-top: auto; }

.ml-auto { margin-left: auto; }
.mr-auto { margin-right: auto; }
.ml-2 { margin-left: 0.5rem; }
.ml-4 { margin-left: 1rem; }
.mr-2 { margin-right: 0.5rem; }
.mr-4 { margin-right: 1rem; }

/* Width */
.w-full { width: 100%; }
.w-auto { width: auto; }
.w-1\/2 { width: 50%; }
.w-1\/3 { width: 33.333333%; }
.w-2\/3 { width: 66.666667%; }
.w-1\/4 { width: 25%; }
.w-3\/4 { width: 75%; }
.w-8 { width: 2rem; }
.w-10 { width: 2.5rem; }
.w-12 { width: 3rem; }
.w-16 { width: 4rem; }
.w-20 { width: 5rem; }
.w-24 { width: 6rem; }

.max-w-xs { max-width: 20rem; }
.max-w-sm { max-width: 24rem; }
.max-w-md { max-width: 28rem; }
.max-w-lg { max-width: 32rem; }
.max-w-xl { max-width: 36rem; }
.max-w-2xl { max-width: 42rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-4xl { max-width: 56rem; }
.max-w-5xl { max-width: 64rem; }
.max-w-6xl { max-width: 72rem; }
.max-w-7xl { max-width: 80rem; }
.max-w-full { max-width: 100%; }
.max-w-screen-xl { max-width: 1280px; }

.min-w-0 { min-width: 0; }

/* Height */
.h-full { height: 100%; }
.h-auto { height: auto; }
.h-screen { height: 100vh; }
.h-8 { height: 2rem; }
.h-10 { height: 2.5rem; }
.h-12 { height: 3rem; }
.h-16 { height: 4rem; }
.h-20 { height: 5rem; }
.h-24 { height: 6rem; }
.h-48 { height: 12rem; }
.h-64 { height: 16rem; }

.min-h-screen { min-height: 100vh; }
.min-h-\[100vh\] { min-height: 100vh; }
.min-h-\[80vh\] { min-height: 80vh; }

/* Position */
.relative { position: relative; }
.absolute { position: absolute; }
.fixed { position: fixed; }
.sticky { position: sticky; }
.static { position: static; }

.inset-0 { top: 0; right: 0; bottom: 0; left: 0; }
.top-0 { top: 0; }
.right-0 { right: 0; }
.bottom-0 { bottom: 0; }
.left-0 { left: 0; }
.top-4 { top: 1rem; }
.top-1\/2 { top: 50%; }
.left-1\/2 { left: 50%; }

/* Z-Index */
.z-0 { z-index: 0; }
.z-10 { z-index: 10; }
.z-20 { z-index: 20; }
.z-30 { z-index: 30; }
.z-40 { z-index: 40; }
.z-50 { z-index: 50; }

/* Overflow */
.overflow-hidden { overflow: hidden; }
.overflow-auto { overflow: auto; }
.overflow-x-auto { overflow-x: auto; }
.overflow-y-auto { overflow-y: auto; }
.overflow-visible { overflow: visible; }

/* Text */
.text-left { text-align: left; }
.text-center { text-align: center; }
.text-right { text-align: right; }

.text-xs { font-size: 0.75rem; line-height: 1rem; }
.text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-base { font-size: 1rem; line-height: 1.5rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; }
.text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
.text-5xl { font-size: 3rem; line-height: 1; }
.text-6xl { font-size: 3.75rem; line-height: 1; }

.font-normal { font-weight: 400; }
.font-medium { font-weight: 500; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }

.leading-none { line-height: 1; }
.leading-tight { line-height: 1.25; }
.leading-snug { line-height: 1.375; }
.leading-normal { line-height: 1.5; }
.leading-relaxed { line-height: 1.625; }
.leading-loose { line-height: 2; }

.tracking-tight { letter-spacing: -0.025em; }
.tracking-normal { letter-spacing: 0; }
.tracking-wide { letter-spacing: 0.025em; }
.tracking-wider { letter-spacing: 0.05em; }
.tracking-widest { letter-spacing: 0.1em; }

.uppercase { text-transform: uppercase; }
.lowercase { text-transform: lowercase; }
.capitalize { text-transform: capitalize; }
.normal-case { text-transform: none; }

.underline { text-decoration: underline; }
.no-underline { text-decoration: none; }
.line-through { text-decoration: line-through; }

.truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.whitespace-nowrap { white-space: nowrap; }
.whitespace-pre-wrap { white-space: pre-wrap; }

.break-words { overflow-wrap: break-word; }

.text-balance { text-wrap: balance; }

/* Colors */
.text-white { color: #ffffff; }
.text-black { color: #000000; }
.text-inherit { color: inherit; }
.text-current { color: currentColor; }
.text-transparent { color: transparent; }

.bg-white { background-color: #ffffff; }
.bg-black { background-color: #000000; }
.bg-transparent { background-color: transparent; }

/* Theme colors (use CSS variables) */
.bg-background { background-color: var(--background); }
.bg-secondary { background-color: var(--background-secondary); }
.bg-card { background-color: var(--card); }
.bg-accent { background-color: var(--accent); }
.bg-accent-light { background-color: var(--accent-light); }

.text-foreground { color: var(--foreground); }
.text-foreground-secondary { color: var(--foreground-secondary); }
.text-accent { color: var(--accent); }
.text-card-foreground { color: var(--card-foreground); }

.border-border { border-color: var(--border); }
.border-card-border { border-color: var(--card-border); }
.border-accent { border-color: var(--accent); }

/* Border */
.border { border-width: 1px; border-style: solid; }
.border-0 { border-width: 0; }
.border-2 { border-width: 2px; }
.border-4 { border-width: 4px; }
.border-t { border-top-width: 1px; border-top-style: solid; }
.border-b { border-bottom-width: 1px; border-bottom-style: solid; }
.border-l { border-left-width: 1px; border-left-style: solid; }
.border-r { border-right-width: 1px; border-right-style: solid; }

.border-transparent { border-color: transparent; }

/* Border Radius */
.rounded { border-radius: var(--radius); }
.rounded-none { border-radius: 0; }
.rounded-sm { border-radius: 0.125rem; }
.rounded-md { border-radius: 0.375rem; }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-xl { border-radius: 0.75rem; }
.rounded-2xl { border-radius: 1rem; }
.rounded-3xl { border-radius: 1.5rem; }
.rounded-full { border-radius: var(--radius-full); }

/* Shadow */
.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow { box-shadow: var(--shadow-md); }
.shadow-md { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.shadow-xl { box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04); }
.shadow-none { box-shadow: none; }

/* Opacity */
.opacity-0 { opacity: 0; }
.opacity-25 { opacity: 0.25; }
.opacity-50 { opacity: 0.5; }
.opacity-75 { opacity: 0.75; }
.opacity-100 { opacity: 1; }

/* Cursor */
.cursor-pointer { cursor: pointer; }
.cursor-default { cursor: default; }
.cursor-not-allowed { cursor: not-allowed; }

/* Pointer Events */
.pointer-events-none { pointer-events: none; }
.pointer-events-auto { pointer-events: auto; }

/* User Select */
.select-none { user-select: none; }
.select-text { user-select: text; }
.select-all { user-select: all; }

/* Transition */
.transition { transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-all { transition-property: all; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-colors { transition-property: color, background-color, border-color, text-decoration-color, fill, stroke; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-transform { transition-property: transform; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }
.transition-opacity { transition-property: opacity; transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); transition-duration: 150ms; }

.duration-150 { transition-duration: 150ms; }
.duration-200 { transition-duration: 200ms; }
.duration-300 { transition-duration: 300ms; }
.duration-500 { transition-duration: 500ms; }
.duration-700 { transition-duration: 700ms; }
.duration-1000 { transition-duration: 1000ms; }

.ease-in { transition-timing-function: cubic-bezier(0.4, 0, 1, 1); }
.ease-out { transition-timing-function: cubic-bezier(0, 0, 0.2, 1); }
.ease-in-out { transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1); }

/* Transform */
.transform { transform: var(--tw-transform); }
.translate-x-0 { transform: translateX(0); }
.translate-y-0 { transform: translateY(0); }
.-translate-x-1\/2 { transform: translateX(-50%); }
.-translate-y-1\/2 { transform: translateY(-50%); }
.translate-x-full { transform: translateX(100%); }
.-translate-x-full { transform: translateX(-100%); }

.scale-100 { transform: scale(1); }
.scale-105 { transform: scale(1.05); }
.scale-110 { transform: scale(1.1); }
.scale-95 { transform: scale(0.95); }
.scale-90 { transform: scale(0.9); }

.rotate-0 { transform: rotate(0deg); }
.rotate-45 { transform: rotate(45deg); }
.rotate-90 { transform: rotate(90deg); }
.rotate-180 { transform: rotate(180deg); }

/* Hover states */
.hover\:scale-105:hover { transform: scale(1.05); }
.hover\:scale-110:hover { transform: scale(1.1); }
.hover\:opacity-80:hover { opacity: 0.8; }
.hover\:opacity-100:hover { opacity: 1; }
.hover\:bg-accent:hover { background-color: var(--accent); }
.hover\:bg-accent-hover:hover { background-color: var(--accent-hover); }
.hover\:text-accent:hover { color: var(--accent); }
.hover\:text-white:hover { color: #ffffff; }
.hover\:shadow-lg:hover { box-shadow: var(--shadow-lg); }
.hover\:shadow-xl:hover { box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04); }
.hover\:-translate-y-1:hover { transform: translateY(-0.25rem); }
.hover\:-translate-y-2:hover { transform: translateY(-0.5rem); }

/* Focus states */
.focus\:outline-none:focus { outline: 2px solid transparent; outline-offset: 2px; }
.focus\:ring-2:focus { box-shadow: 0 0 0 2px var(--accent); }
.focus-visible\:outline-none:focus-visible { outline: 2px solid transparent; outline-offset: 2px; }
.focus-visible\:ring-2:focus-visible { box-shadow: 0 0 0 2px var(--accent); }

/* Group hover */
.group:hover .group-hover\:opacity-100 { opacity: 1; }
.group:hover .group-hover\:translate-y-0 { transform: translateY(0); }
.group:hover .group-hover\:scale-110 { transform: scale(1.1); }

/* Object Fit */
.object-cover { object-fit: cover; }
.object-contain { object-fit: contain; }
.object-fill { object-fit: fill; }
.object-center { object-position: center; }

/* Aspect Ratio */
.aspect-video { aspect-ratio: 16 / 9; }
.aspect-square { aspect-ratio: 1 / 1; }
.aspect-\[4\/3\] { aspect-ratio: 4 / 3; }

/* List Style */
.list-none { list-style-type: none; }
.list-disc { list-style-type: disc; }
.list-inside { list-style-position: inside; }

/* Backdrop */
.backdrop-blur-sm { backdrop-filter: blur(4px); }
.backdrop-blur { backdrop-filter: blur(8px); }
.backdrop-blur-md { backdrop-filter: blur(12px); }
.backdrop-blur-lg { backdrop-filter: blur(16px); }

/* Space Between (using margin on children) */
.space-y-1 > * + * { margin-top: 0.25rem; }
.space-y-2 > * + * { margin-top: 0.5rem; }
.space-y-3 > * + * { margin-top: 0.75rem; }
.space-y-4 > * + * { margin-top: 1rem; }
.space-y-6 > * + * { margin-top: 1.5rem; }
.space-y-8 > * + * { margin-top: 2rem; }

.space-x-1 > * + * { margin-left: 0.25rem; }
.space-x-2 > * + * { margin-left: 0.5rem; }
.space-x-3 > * + * { margin-left: 0.75rem; }
.space-x-4 > * + * { margin-left: 1rem; }
.space-x-6 > * + * { margin-left: 1.5rem; }

/* ============================================
   Responsive Utilities
============================================ */
@media (min-width: 640px) {
  .sm\:flex { display: flex; }
  .sm\:hidden { display: none; }
  .sm\:block { display: block; }
  .sm\:grid { display: grid; }
  .sm\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sm\:flex-row { flex-direction: row; }
  .sm\:text-left { text-align: left; }
  .sm\:text-center { text-align: center; }
  .sm\:text-lg { font-size: 1.125rem; line-height: 1.75rem; }
  .sm\:text-xl { font-size: 1.25rem; line-height: 1.75rem; }
  .sm\:text-2xl { font-size: 1.5rem; line-height: 2rem; }
  .sm\:px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
  .sm\:py-8 { padding-top: 2rem; padding-bottom: 2rem; }
}

@media (min-width: 768px) {
  .md\:flex { display: flex; }
  .md\:hidden { display: none; }
  .md\:block { display: block; }
  .md\:inline-flex { display: inline-flex; }
  .md\:grid { display: grid; }
  .md\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .md\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .md\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .md\:flex-row { flex-direction: row; }
  .md\:flex-col { flex-direction: column; }
  .md\:items-center { align-items: center; }
  .md\:justify-between { justify-content: space-between; }
  .md\:gap-6 { gap: 1.5rem; }
  .md\:gap-8 { gap: 2rem; }
  .md\:gap-12 { gap: 3rem; }
  .md\:text-left { text-align: left; }
  .md\:text-center { text-align: center; }
  .md\:text-xl { font-size: 1.25rem; line-height: 1.75rem; }
  .md\:text-2xl { font-size: 1.5rem; line-height: 2rem; }
  .md\:text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
  .md\:text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
  .md\:text-5xl { font-size: 3rem; line-height: 1; }
  .md\:text-6xl { font-size: 3.75rem; line-height: 1; }
  .md\:w-1\/2 { width: 50%; }
  .md\:w-1\/3 { width: 33.333333%; }
  .md\:w-2\/3 { width: 66.666667%; }
  .md\:w-auto { width: auto; }
  .md\:px-8 { padding-left: 2rem; padding-right: 2rem; }
  .md\:py-12 { padding-top: 3rem; padding-bottom: 3rem; }
  .md\:py-20 { padding-top: 5rem; padding-bottom: 5rem; }
  .md\:py-24 { padding-top: 6rem; padding-bottom: 6rem; }
  .md\:p-8 { padding: 2rem; }
  .md\:mb-0 { margin-bottom: 0; }
  .md\:mt-0 { margin-top: 0; }
  .md\:space-y-0 > * + * { margin-top: 0; }
  .md\:max-w-md { max-width: 28rem; }
  .md\:max-w-lg { max-width: 32rem; }
  .md\:max-w-xl { max-width: 36rem; }
  .md\:max-w-2xl { max-width: 42rem; }
}

@media (min-width: 1024px) {
  .lg\:flex { display: flex; }
  .lg\:hidden { display: none; }
  .lg\:block { display: block; }
  .lg\:grid { display: grid; }
  .lg\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lg\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .lg\:grid-cols-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .lg\:flex-row { flex-direction: row; }
  .lg\:items-start { align-items: flex-start; }
  .lg\:gap-8 { gap: 2rem; }
  .lg\:gap-12 { gap: 3rem; }
  .lg\:gap-16 { gap: 4rem; }
  .lg\:text-left { text-align: left; }
  .lg\:text-2xl { font-size: 1.5rem; line-height: 2rem; }
  .lg\:text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
  .lg\:text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
  .lg\:text-5xl { font-size: 3rem; line-height: 1; }
  .lg\:text-6xl { font-size: 3.75rem; line-height: 1; }
  .lg\:text-7xl { font-size: 4.5rem; line-height: 1; }
  .lg\:w-1\/2 { width: 50%; }
  .lg\:w-1\/3 { width: 33.333333%; }
  .lg\:w-2\/5 { width: 40%; }
  .lg\:w-3\/5 { width: 60%; }
  .lg\:px-8 { padding-left: 2rem; padding-right: 2rem; }
  .lg\:py-24 { padding-top: 6rem; padding-bottom: 6rem; }
  .lg\:py-32 { padding-top: 8rem; padding-bottom: 8rem; }
  .lg\:max-w-none { max-width: none; }
  .lg\:sticky { position: sticky; }
  .lg\:top-8 { top: 2rem; }
}

@media (min-width: 1280px) {
  .xl\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .xl\:text-7xl { font-size: 4.5rem; line-height: 1; }
  .xl\:px-0 { padding-left: 0; padding-right: 0; }
}

/* ============================================================
   AI CHATBOT — フローティングチャット
   ============================================================ */

/* --- フローティングボタン --- */
.npc-chat-fab {
  position: fixed;
  bottom: 2.5rem;
  right: 1.5rem;
  z-index: 9998;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  background: var(--background);
  color: var(--accent);
  font-size: 1.4rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.npc-chat-fab:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(0,0,0,0.4);
  background: var(--accent);
  color: var(--background);
}

.npc-chat-fab::after {
  content: '';
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1px solid var(--accent);
  opacity: 0;
  animation: npcChatPulse 3s ease-in-out infinite;
}

@keyframes npcChatPulse {
  0%, 100% { opacity: 0; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(1.15); }
}

.npc-chat-fab.hidden { display: none; }

/* --- チャットパネル --- */
.npc-chat-panel {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 9999;
  width: 380px;
  height: 520px;
  max-height: calc(100vh - 3rem);
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  opacity: 0;
  pointer-events: none;
  transform: translateY(20px) scale(0.95);
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 16px 60px rgba(0,0,0,0.3);
  overflow: hidden;
}

.npc-chat-panel.open {
  opacity: 1;
  pointer-events: all;
  transform: translateY(0) scale(1);
}

/* ヘッダー */
.npc-chat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--border);
  background: var(--background-secondary);
}

.npc-chat-header-info {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.npc-chat-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--background);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  font-family: var(--font-heading);
}

.npc-chat-title {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--foreground);
}

.npc-chat-status {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.65rem;
  color: var(--foreground-secondary);
}

.npc-chat-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: npcDotPulse 2s ease-in-out infinite;
}

@keyframes npcDotPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.npc-chat-close {
  width: 28px;
  height: 28px;
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--foreground-secondary);
  font-size: 0.85rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.npc-chat-close:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* メッセージエリア */
.npc-chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}

.npc-chat-messages::-webkit-scrollbar { width: 4px; }
.npc-chat-messages::-webkit-scrollbar-track { background: transparent; }
.npc-chat-messages::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

.npc-chat-msg {
  max-width: 85%;
  animation: npcMsgIn 0.3s ease-out both;
}

@keyframes npcMsgIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.npc-chat-msg--ai { align-self: flex-start; }
.npc-chat-msg--user { align-self: flex-end; }

.npc-chat-bubble {
  padding: 0.7rem 1rem;
  font-size: 0.85rem;
  line-height: 1.7;
  border-radius: 10px;
  font-family: var(--font-body);
}

.npc-chat-msg--ai .npc-chat-bubble {
  background: var(--background-secondary);
  border: 1px solid var(--border);
  color: var(--foreground);
  border-bottom-left-radius: 2px;
}

.npc-chat-msg--user .npc-chat-bubble {
  background: var(--accent);
  color: var(--background);
  border-bottom-right-radius: 2px;
}

/* タイピングインジケーター */
.npc-chat-typing {
  display: flex;
  gap: 4px;
  padding: 0.7rem 1rem;
  align-self: flex-start;
}

.npc-chat-typing span {
  width: 5px;
  height: 5px;
  background: var(--accent);
  border-radius: 50%;
  opacity: 0.4;
  animation: npcTyping 1.4s ease-in-out infinite;
}

.npc-chat-typing span:nth-child(2) { animation-delay: 0.15s; }
.npc-chat-typing span:nth-child(3) { animation-delay: 0.3s; }

@keyframes npcTyping {
  0%, 60%, 100% { opacity: 0.4; transform: translateY(0); }
  30% { opacity: 1; transform: translateY(-4px); }
}

/* 入力エリア */
.npc-chat-input {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem;
  border-top: 1px solid var(--border);
  background: var(--background-secondary);
}

.npc-chat-input input {
  flex: 1;
  background: var(--background);
  border: 1px solid var(--border);
  padding: 0.65rem 0.8rem;
  font-family: var(--font-body);
  font-size: 0.85rem;
  color: var(--foreground);
  border-radius: 8px;
  outline: none;
  transition: border-color 0.2s ease;
}

.npc-chat-input input::placeholder { color: var(--foreground-secondary); }
.npc-chat-input input:focus { border-color: var(--accent); }

.npc-chat-send {
  width: 36px;
  height: 36px;
  background: var(--accent);
  border: none;
  border-radius: 8px;
  color: var(--background);
  font-size: 0.9rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.npc-chat-send:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* モバイル対応 */
@media (max-width: 480px) {
  .npc-chat-panel {
    width: calc(100vw - 2rem);
    height: calc(100vh - 6rem);
    bottom: 1rem;
    right: 1rem;
  }
}

/* Gamerテーマ用チャットボット装飾 */
[data-theme="gamer"] .npc-chat-fab {
  border-color: var(--neon-cyan);
  box-shadow: 0 0 15px rgba(0, 255, 255, 0.3);
}

[data-theme="gamer"] .npc-chat-fab:hover {
  background: var(--neon-cyan);
  color: #0a0a0f;
  box-shadow: 0 0 25px rgba(0, 255, 255, 0.5);
}

[data-theme="gamer"] .npc-chat-panel {
  border-color: var(--card-border);
  box-shadow: 0 0 40px rgba(0, 255, 255, 0.1);
}

[data-theme="gamer"] .npc-chat-msg--user .npc-chat-bubble {
  background: var(--neon-cyan);
  color: #0a0a0f;
}

/* Cosmeテーマ用チャットボット装飾 */
[data-theme="cosme"] .npc-chat-fab {
  border-radius: 50%;
  box-shadow: var(--shadow-lg);
}

[data-theme="cosme"] .npc-chat-panel {
  border-radius: 1.5rem;
}

[data-theme="cosme"] .npc-chat-msg--user .npc-chat-bubble {
  background: linear-gradient(90deg, var(--accent), #ffb347);
  color: white;
}

/* ==========================================
   SP QA Round 1 修正 (2026-04-11)
   BUG-001: SPではback-to-top非表示（iOSのステータスバータップで代替）
   BUG-002: theme-switcher のSP幅・タップ領域 WCAG 44px 確保
              + SPではtheme-switcherを左下に寄せる（back-to-topが空いた場所）
   ========================================== */
@media (max-width: 640px) {
  .back-to-top {
    display: none !important;
  }
  .theme-switcher {
    left: 1.5rem;
    right: auto;
    max-width: calc(100vw - 3rem);
    transform: translateX(0) translateY(100px);
  }
  .theme-switcher.animate-in {
    transform: translateX(0) translateY(0);
  }
  .theme-btn {
    min-height: 44px;
    min-width: 44px;
  }
  /* テーマ説明テキストもSPでは左寄せ */
  .theme-label-display {
    left: 1.5rem;
    right: auto;
    text-align: left;
    transform: translateX(0) translateY(20px);
  }
  .theme-label-display.animate-in {
    transform: translateX(0) translateY(0);
  }
}

/* ==========================================
   SP QA Round 2/3 修正 (2026-04-11)
   BUG-003: ブログ・固定ページの table に横スクロール対応
   BUG-006: ブログ前後記事ナビの SP 1列化
   ========================================== */
.blog-body-content table,
.page-body table,
.npc-table {
  display: block;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
}

@media (max-width: 640px) {
  .blog-post-nav {
    grid-template-columns: 1fr !important;
  }
  .post-nav-next {
    text-align: left !important;
  }
}
