/* =================================
   CSS変数定義
================================= */
:root {
  --edo-ai: #4A90E2; --kon-iro: #2E86C1; --hanada: #5DADE2; --asagi: #2E86C1; --mizu-iro: #AED6F1; --sora-iro: #85C1E9;
  --text-primary: #333; --text-secondary: #666; --text-inverse: #fff; --text-muted: #999;
  --bg-primary: #fff; --bg-secondary: #f8f9fa; --bg-tertiary: #f5f7fa;
  --surface: #fff; --border-light: #e9ecef; --border-medium: #dee2e6; --border-radius: 8px;
  --snow-white: #fff;
  --shadow-medium: 0 4px 16px rgba(0,0,0,0.08); --shadow-blue: 0 8px 32px rgba(74,144,226,0.3); --shadow-blue-light: 0 4px 16px rgba(74,144,226,0.15);
  --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  --font-display: 'Noto Sans JP', sans-serif; --font-main: 'Noto Sans JP', sans-serif; --font-accent: 'Noto Sans JP', sans-serif;
  --header-height: 80px;
  
  /* 背景画像 */
  --bg-image-1: url('../media/background/背景した全部イラスト.png');
  --bg-image-2: url('../media/background/東京都地図背景透過.png');
  --bg-image-3: url('../media/background/浅草最高だぜ.png');
  --bg-image-opacity: 0.05;
  --bg-overlay-color: rgba(255, 255, 255, 0.85);
}

/* フォント読み込み */
@import url('https://fonts.googleapis.com/css2?family=Noto+Serif+JP:wght@400;500;600;700;900&family=Noto+Sans+JP:wght@300;400;500;600;700;800&family=Zen+Kaku+Gothic+New:wght@400;500;700;900&display=swap');

/* =================================
   リセット・ベース
================================= */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: var(--font-main); background-color: var(--bg-primary); color: var(--text-primary); line-height: 1.8; font-size: 16px; font-weight: 400; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; position: relative; overflow-x: hidden; padding-top: var(--header-height); }

/* 背景レイヤー */
body::before, body::after { content: ''; position: fixed; inset: 0; z-index: -10; }
body::before { background-image: var(--bg-image-1); background-size: cover; background-position: center; background-repeat: no-repeat; background-attachment: fixed; opacity: var(--bg-image-opacity); z-index: -4; filter: grayscale(100%) sepia(10%) brightness(1.1); }
body::after { background: var(--bg-overlay-color); z-index: -3; }

a { text-decoration: none; color: inherit; transition: var(--transition); }
ul { list-style: none; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 32px; }
h1, h2, h3, h4, h5, h6 { font-family: var(--font-display); font-weight: 700; color: var(--text-primary); letter-spacing: 0.02em; }

/* =================================
   ヘッダー・ナビゲーション
================================= */
header { background: rgba(255, 255, 255, 1.0); backdrop-filter: blur(20px); border-bottom: 1px solid var(--border-light); position: fixed; inset: 0 0 auto 0; z-index: 1000; transition: transform 0.4s cubic-bezier(0.25, 0.8, 0.25, 1); height: 80px; }
header.header-hidden { transform: translateY(-100%); }
.header-content { display: flex; justify-content: space-between; align-items: center; height: 80px; }

/* ロゴ */
.logo { display: flex; align-items: center; flex-shrink: 0; text-decoration: none; }
.logo-image { height: 30px; width: auto; margin-right: 15px; }
.logo-text { text-align: left; }
.logo-title { font-family: var(--font-display); font-size: 20px; font-weight: 700; color: var(--edo-ai); margin-bottom: 2px; letter-spacing: 0.1em; }
.logo-subtitle { font-family: var(--font-accent); font-size: 9px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.15em; }

/* ナビゲーション */
.nav-wrapper { display: flex; align-items: center; gap: 40px; }
.nav-menu { display: flex; align-items: center; gap: 32px; }
.nav-item { position: relative; }
.nav-link { color: var(--text-primary); padding: 8px 0; display: block; font-family: var(--font-accent); font-weight: 500; font-size: 14px; letter-spacing: 0.05em; position: relative; transition: color 0.3s ease; }

/* ホバーエフェクト */
.nav-link::before, .nav-link::after { content: ''; position: absolute; bottom: -2px; width: 0; height: 2px; transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1); }
.nav-link::before { left: 0; background: linear-gradient(90deg, var(--edo-ai), var(--aozora)); }
.nav-link::after { right: 0; background: linear-gradient(90deg, var(--aozora), var(--edo-ai)); transition-delay: 0.1s; }
.nav-item:hover .nav-link::before, .nav-item:hover .nav-link::after { width: 50%; }
.nav-item:hover .nav-link { color: var(--edo-ai); }

/* ドロップダウン */
.dropdown { position: absolute; top: calc(100% + 20px); left: 50%; transform: translateX(-50%) translateY(10px); background: var(--surface); border: 1px solid var(--border-light); box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1); min-width: 280px; border-radius: var(--border-radius); padding: 8px 0; opacity: 0; visibility: hidden; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); }
.nav-item:hover .dropdown { opacity: 1; visibility: visible; transform: translateX(-50%) translateY(0); }
.dropdown-item { padding: 12px 24px; transition: all 0.2s ease; position: relative; overflow: hidden; }
.dropdown-item::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: linear-gradient(180deg, var(--edo-ai), var(--aozora)); transform: translateX(-3px); transition: transform 0.3s ease; }
.dropdown-item:hover::before { transform: translateX(0); }
.dropdown-item:hover { background: var(--bg-secondary); padding-left: 32px; }
.dropdown-item a { display: block; font-family: var(--font-accent); font-weight: 400; font-size: 13px; color: var(--text-secondary); letter-spacing: 0.03em; }
.dropdown-item:hover a { color: var(--text-primary); }

/* CTAボタン */
.cta-button { background: var(--edo-ai); color: var(--text-inverse); padding: 12px 28px; border-radius: var(--border-radius); font-family: var(--font-accent); font-weight: 600; font-size: 13px; letter-spacing: 0.1em; position: relative; overflow: hidden; transition: all 0.3s ease; border: 2px solid var(--edo-ai); }
.cta-button::before { content: ''; position: absolute; top: 50%; left: 50%; width: 0; height: 0; background: var(--aozora); border-radius: 50%; transform: translate(-50%, -50%); transition: width 0.4s ease, height 0.4s ease; }
.cta-button:hover::before { width: 300%; height: 300%; }
.cta-button:hover { color: var(--text-inverse); border-color: var(--aozora); transform: translateY(-2px); box-shadow: var(--shadow-blue); }
.cta-main { position: relative; z-index: 1; }

/* ハンバーガーメニュー */
.hamburger { display: none; cursor: pointer; padding: 8px; background: transparent; border: none; position: relative; width: 40px; height: 40px; }
.hamburger span { display: block; width: 24px; height: 2px; margin: 5px auto; background: var(--text-primary); transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1); position: relative; }
.hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; transform: scale(0); }
.hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* 固定ハンバーガーメニュー */
.hamburger-fixed { position: fixed; top: 20px; right: 20px; z-index: 1001; display: none; cursor: pointer; padding: 12px; background: var(--surface); border: 1px solid var(--border-light); border-radius: var(--border-radius); box-shadow: var(--shadow-medium); transition: all 0.3s ease; opacity: 0; transform: translateY(-10px); width: 48px; height: 48px; align-items: center; justify-content: center; }
.hamburger-fixed.show { display: flex; opacity: 1; transform: translateY(0); }
.hamburger-fixed span { display: block; width: 24px; height: 2px; margin: 4px 0; background: var(--text-primary); transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1); position: absolute; left: 50%; transform: translateX(-50%); }
.hamburger-fixed span:nth-child(1) { top: 14px; }
.hamburger-fixed span:nth-child(2) { top: 50%; transform: translate(-50%, -50%); }
.hamburger-fixed span:nth-child(3) { bottom: 14px; }
.hamburger-fixed.active span:nth-child(1) { top: 50%; transform: translate(-50%, -50%) rotate(45deg); }
.hamburger-fixed.active span:nth-child(2) { opacity: 0; }
.hamburger-fixed.active span:nth-child(3) { bottom: 50%; transform: translate(-50%, 50%) rotate(-45deg); }

/* モバイルメニュー */
.mobile-menu { position: fixed; top: 0; right: -100%; width: 100%; max-width: 400px; height: 100vh; background: var(--surface); box-shadow: -4px 0 20px rgba(0, 0, 0, 0.1); transition: right 0.4s cubic-bezier(0.25, 0.8, 0.25, 1); z-index: 999; overflow-y: auto; padding: 80px 32px 32px; }
.mobile-menu.active { right: 0; }
.mobile-nav-item { margin-bottom: 8px; }
.mobile-nav-link { font-family: var(--font-accent); font-size: 16px; font-weight: 500; color: var(--text-primary); display: flex; justify-content: space-between; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--border-light); transition: all 0.3s ease; cursor: pointer; }
.mobile-nav-link:hover { color: var(--edo-ai); padding-left: 12px; }

/* CTA専用モバイルリンク */
.mobile-nav-link.cta-style { 
  background: transparent; 
  color: var(--text-inverse); /* 修正: 通常時の文字色を見える色に変更 */
  border-bottom: 2px solid var(--edo-ai); 
  padding: 16px 0 16px 14px; 
  margin: 16px 0 8px 0; 
  justify-content: space-between; 
  font-weight: 600; 
  letter-spacing: 0.02em; 
  position: relative; 
  overflow: hidden; 
}
.mobile-nav-link.cta-style::before { 
  content: ''; 
  position: absolute; 
  inset: 0 0 0 -100%; 
  background: var(--edo-ai); 
  transition: left 0.3s ease; 
  z-index: -1; 
}
.mobile-nav-link.cta-style:hover { 
  color: var(--text-inverse); 
  padding-left: 16px; 
  transform: none; 
  box-shadow: none; 
}
.mobile-nav-link.cta-style:hover::before { 
  left: 0; 
}
.mobile-nav-link.cta-style::after { 
  content: '→'; 
  font-size: 18px; 
  transition: transform 0.3s ease; 
  margin-left: 8px; 
  margin-right: 8px; 
}
.mobile-nav-link.cta-style:hover::after { 
  transform: translateX(4px); 
}

.mobile-nav-link.has-dropdown::after { content: '+'; font-size: 20px; font-weight: 300; transition: transform 0.3s ease; }
.mobile-nav-link.has-dropdown.active::after { transform: rotate(45deg); }

/* モバイルドロップダウン */
.mobile-dropdown { max-height: 0; overflow: hidden; transition: max-height 0.3s ease-out; margin-bottom: 8px; }
.mobile-dropdown.active { max-height: 500px; transition: max-height 0.4s ease-in; }
.mobile-dropdown-item { padding: 12px 0 12px 24px; border-left: 2px solid var(--border-light); margin-left: 12px; }
.mobile-dropdown-item a { font-family: var(--font-accent); font-size: 14px; color: var(--text-secondary); display: block; transition: all 0.3s ease; }
.mobile-dropdown-item:hover a { color: var(--edo-ai); padding-left: 8px; }

/* =================================
   ボタン統一スタイル
================================= */
.content-button, .view-all-btn, .join-button, .contact-button { display: inline-flex; align-items: center; gap: 12px; padding: 16px 32px; font-family: var(--font-accent); font-weight: 600; font-size: 14px; text-decoration: none; background: var(--snow-white); color: var(--edo-ai); border: 2px solid var(--edo-ai); border-radius: var(--border-radius); cursor: pointer; transition: var(--transition); overflow: hidden; position: relative; letter-spacing: 0.05em; z-index: 1; box-shadow: var(--shadow-blue-light); }
.content-button::before, .view-all-btn::before, .join-button::before, .contact-button::before { content: ''; position: absolute; inset: 0 100% 0 0; background: linear-gradient(135deg, var(--edo-ai), var(--aozora)); transition: right 0.4s ease; z-index: -1; }
.content-button:hover::before, .view-all-btn:hover::before, .join-button:hover::before, .contact-button:hover::before { right: 0; }
.content-button:hover, .view-all-btn:hover, .join-button:hover, .contact-button:hover { color: var(--text-inverse); border-color: var(--aozora); box-shadow: var(--shadow-blue); }

/* ゴールドボタン */
.button-gold { border-color: var(--gold-accent); color: var(--text-primary); background: var(--gold-accent); box-shadow: 0 4px 16px rgba(212, 175, 55, 0.2); }
.button-gold::before { background: var(--text-primary); }
.button-gold:hover { color: var(--gold-accent); background: transparent; border-color: var(--gold-accent); }

/* =================================
   フッター
================================= */
footer { background: var(--edo-ai); color: var(--text-inverse); padding: 80px 0 40px; position: relative; z-index: 5; }
footer::before { content: ''; position: absolute; top: 0; left: 10%; right: 10%; height: 1px; background: var(--sora-iro); opacity: 0.3; }
.footer-top { display: grid; grid-template-columns: 2fr repeat(3, 1fr); gap: 60px; margin-bottom: 60px; position: relative; z-index: 1; }
.footer-info h3 { font-family: var(--font-display); color: var(--text-inverse); font-size: 20px; font-weight: 700; margin-bottom: 24px; letter-spacing: 0.05em; }
.footer-info p { margin-bottom: 20px; line-height: 1.8; color: var(--mizu-iro); font-weight: 400; }

.footer-contact { margin-top: 24px; }
.contact-item { display: flex; align-items: center; margin-bottom: 16px; transition: var(--transition); color: var(--mizu-iro); }
.contact-item:hover { color: var(--text-inverse); transform: translateX(8px); }
.contact-icon { width: 20px; text-align: center; margin-right: 12px; font-size: 14px; }

.footer-links h4 { font-family: var(--font-accent); color: var(--text-inverse); font-size: 16px; font-weight: 600; margin-bottom: 24px; letter-spacing: 0.03em; position: relative; padding-bottom: 8px; }
.footer-links h4::after { content: ''; position: absolute; bottom: 0; left: 0; width: 24px; height: 1px; background: var(--sora-iro); }
.footer-links ul li { margin-bottom: 12px; }
.footer-links ul li a { color: var(--mizu-iro); transition: var(--transition); display: flex; align-items: center; font-weight: 400; font-size: 13px; }
.footer-links ul li a:hover { color: var(--text-inverse); padding-left: 8px; }
.link-icon { font-size: 12px; margin-right: 8px; transition: var(--transition); }
.footer-links ul li a:hover .link-icon { transform: translateX(4px); }

.footer-bottom { text-align: center; padding-top: 40px; border-top: 1px solid rgba(255, 255, 255, 0.1); font-size: 12px; color: var(--sora-iro); position: relative; z-index: 1; }

/* =================================
   色調整・ユーティリティ
================================= */
.desc-lead { font-family: var(--font-accent); font-weight: 600; color: var(--text-primary); }
.section-badge { color: var(--edo-ai); border-color: var(--edo-ai); }
.counter { color: var(--edo-ai); font-weight: 700; }
.highlight-box { border-color: var(--edo-ai); }
.highlight-label { color: var(--text-muted); }
.highlight-value { color: var(--edo-ai); }
.schedule-icon { background-color: var(--edo-ai); color: var(--text-inverse); }
.news-category { background-color: var(--edo-ai); color: var(--text-inverse); }
.area-header { border-left-color: var(--edo-ai); }
.area-name { color: var(--edo-ai); }

.branch-button { border-color: var(--border-light); background: var(--snow-white); color: var(--text-primary); box-shadow: var(--shadow-blue-light); }
.branch-button:hover { border-color: var(--edo-ai); color: var(--edo-ai); background-color: rgba(74, 123, 167, 0.05); box-shadow: var(--shadow-blue); }

.card { background: var(--snow-white); border: 1px solid var(--border-light); box-shadow: var(--shadow-blue-light); }
.card:hover { box-shadow: var(--shadow-blue); border-color: var(--asagi); }

a.text-link { color: var(--edo-ai); }
a.text-link:hover { color: var(--aozora); }

.active, .current { color: var(--edo-ai) !important; border-color: var(--edo-ai) !important; }

input:focus, textarea:focus, select:focus { border-color: var(--edo-ai); box-shadow: 0 0 0 3px rgba(74, 123, 167, 0.1); }

/* =================================
   ページヘッダー・パンくずリスト
================================= */

/* ページヘッダー */
.page-header {
  background: var(--bg-primary);
  padding: 60px 0 120px;
  position: relative;
  border-bottom: 1px solid var(--border-light);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* 背景画像付きヘッダーの場合のオーバーレイ */
.page-header[data-bg-image]::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(250, 250, 248, 0.85);
  z-index: 1;
}

.page-header[data-bg-image] .container {
  position: relative;
  z-index: 2;
}

/* 背景画像用のバリエーション */
.page-header.bg-tokyo-map {
  background-image: var(--bg-image-2);
}

.page-header.bg-asakusa {
  background-image: var(--bg-image-3);
}

.page-header.bg-illustration {
  background-image: var(--bg-image-1);
}

/* カスタム背景画像 */
.page-header.custom-bg {
  background-attachment: fixed;
}

.page-header.custom-bg::before {
  background: rgba(250, 250, 248, 0.9);
}

/* ページタイトル */
.page-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 1rem;
  letter-spacing: 0.03em;
  text-align: center;
  line-height: 1.3;
  position: relative;
}

.page-title::after {
  content: '';
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 2px;
  background: var(--edo-ai);
  border-radius: 1px;
}

/* パンくずリスト */
.breadcrumb {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  margin-top: 1.5rem;
  flex-wrap: wrap;
}

.breadcrumb-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.breadcrumb-item:not(:last-child)::after {
  content: '>';
  color: var(--text-muted);
  font-size: 0.8rem;
  margin-left: 0.25rem;
}

.breadcrumb a {
  color: var(--edo-ai);
  font-family: var(--font-accent);
  font-weight: 400;
  text-decoration: none;
  transition: color 0.2s ease;
}

.breadcrumb a:hover {
  color: var(--aozora);
  text-decoration: underline;
}

.breadcrumb span {
  color: var(--text-secondary);
  font-family: var(--font-accent);
  font-weight: 400;
}

/* =================================
   背景パターン
================================= */
.bg-pattern { position: relative; }
.bg-pattern::before { 
  content: ''; 
  position: absolute; 
  inset: 0; 
  background-size: cover; 
  background-position: center; 
  background-repeat: no-repeat; 
  z-index: -1; 
  pointer-events: none; 
  opacity: var(--bg-image-opacity); 
}

.bg-pattern-1::before { 
  background-image: var(--bg-image-1); 
}

.bg-pattern-2::before { 
  background-image: var(--bg-image-2); 
}

.bg-pattern-3::before { 
  background-image: var(--bg-image-3); 
}

/* =================================
   レスポンシブ
================================= */
@media (max-width: 968px) {
  .nav-menu { display: none; }
  .hamburger { display: block; }
  .nav-wrapper { gap: 20px; }
  .desktop-only { display: none; }
  .footer-top { grid-template-columns: repeat(2, 1fr); gap: 40px; }
}

@media (max-width: 768px) {
  body { padding-top: var(--header-height-collapsed); }
  .container { padding: 0 20px; }
  .logo-title { font-size: 20px; }
  .footer-top { grid-template-columns: 1fr; gap: 40px; }
  body::before { background-attachment: scroll; }
  
  /* ページヘッダーレスポンシブ */
  .page-header { 
    padding: 100px 0 50px; 
    background-attachment: scroll;
  }
  
  .page-header[data-bg-image]::before {
    background: rgba(250, 250, 248, 0.9);
  }
  
  .page-title { 
    font-size: clamp(1.6rem, 3vw, 2rem);
    margin-bottom: 0.8rem;
  }
  
  .page-title::after { 
    width: 30px; 
  }
  
  .breadcrumb { 
    font-size: 0.85rem;
    margin-top: 1rem;
  }
}

@media (max-width: 640px) {
  .logo-title { font-size: 18px; }
  .logo-subtitle { font-size: 8px; }
  .cta-button { padding: 10px 20px; font-size: 12px; }
  
  /* ページヘッダー小画面対応 */
  .page-header { 
    padding: 90px 0 40px; 
  }
  
  .page-title { 
    font-size: clamp(1.4rem, 3vw, 1.8rem);
  }
  
  .breadcrumb { 
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .logo-title { font-size: 18px; }
  .cta-button { font-size: 11px; padding: 10px 16px; }
  
  /* ページヘッダー極小画面対応 */
  .page-header { 
    padding: 80px 0 40px; 
  }
  
  .page-title { 
    font-size: clamp(1.2rem, 2.5vw, 1.6rem);
    margin-bottom: 0.8rem;
  }
  
  .page-title::after { 
    width: 25px; 
  }
  
  .breadcrumb { 
    font-size: 0.75rem;
    gap: 0.3rem;
  }
}

/* その他ユーティリティ */
body.menu-open { overflow: hidden; }
.header-scroll-hidden { transform: translateY(-100%); }

/* =================================
   統一アニメーションシステム
================================= */
/* スタッガーアニメーション基本設定 */
.stagger-animation {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.stagger-animation.animated {
  opacity: 1;
  transform: translateY(0);
}

/* キーフレームアニメーション */
@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* スケジュールアイテム用スタッガーアニメーション */
.schedule-item.stagger-animation {
  animation: slideInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* アニメーション遅延（8つまで対応） */
.schedule-item:nth-child(1) { animation-delay: 0.1s; }
.schedule-item:nth-child(2) { animation-delay: 0.2s; }
.schedule-item:nth-child(3) { animation-delay: 0.3s; }
.schedule-item:nth-child(4) { animation-delay: 0.4s; }
.schedule-item:nth-child(5) { animation-delay: 0.5s; }
.schedule-item:nth-child(6) { animation-delay: 0.6s; }
.schedule-item:nth-child(7) { animation-delay: 0.7s; }
.schedule-item:nth-child(8) { animation-delay: 0.8s; }

/* アクセシビリティ配慮：アニメーション削減設定 */
@media (prefers-reduced-motion: reduce) {
  .stagger-animation, .schedule-item.stagger-animation {
    animation: none !important;
    transition: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
}