/* ============================================================
   common.css — LP全ページ共通の基盤
   (変数 / リセット / container / ボタン / ヘッダー / ハンバーガー /
    モバイルメニュー / フッター)
   index.html と法務系ページで同じ定義を使い、画面遷移時のズレをなくす
============================================================ */

:root {
  --primary: #5273C7;
  --primary-dark: #4361B0;
  --primary-light: #F0F4FB;
  --primary-gradient: linear-gradient(135deg, #5273C7 0%, #6A8AD8 100%);

  --accent: #6070BE;
  --accent-light: #ECEEF8;
  --accent-dark: #4F5CA3;
  --accent-secondary: #7A88C8;
  --accent-muted: #9EA8D0;
  --accent-green: #22C55E;
  --accent-amber: #F59E0B;

  --text-primary: #1E293B;
  --text-secondary: #475569;
  --text-muted: #94A3B8;
  --text-light: #CBD5E1;

  --bg-white: #FFFFFF;
  --bg-cream: #FAFBFD;
  --bg-light: #F8FAFC;
  --bg-section: #F1F5F9;
  --bg-dark: #1E293B;
  --bg-gradient: linear-gradient(180deg, #FFFFFF 0%, #F8FAFC 100%);

  --border: #E2E8F0;
  --border-light: #F1F5F9;
  --border-accent: rgba(96, 112, 190, 0.2);

  --gray-100: #F1F5F9;

  --border-accent: rgba(96, 112, 190, 0.2);

  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.03);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.03);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.08);
  --shadow-xl: 0 24px 48px rgba(0, 0, 0, 0.1);
  --shadow-glow: 0 0 32px rgba(96, 112, 190, 0.12);
  --shadow-primary: 0 8px 24px rgba(82, 115, 199, 0.2);

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --radius-2xl: 28px;

  --transition-fast: 0.15s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Noto Sans JP', 'DM Sans', sans-serif;
  font-size: 16px;
  line-height: 1.8;
  color: var(--text-primary);
  background: var(--bg-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'palt' 1;
  letter-spacing: 0.02em;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Sora', 'Noto Sans JP', sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
}

/* Grain Texture Overlay (全ページ共通) */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.015;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ========================================
   Buttons
   ======================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 28px;
  font-family: 'Sora', 'Noto Sans JP', sans-serif;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-base);
  border: none;
  position: relative;
  overflow: hidden;
  letter-spacing: 0.01em;
}

/* Premium Shine Effect */
.btn-primary::before,
.btn-white::before,
.btn-amber::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  animation: shine 4s ease-in-out infinite;
}

.header-cta .btn-primary::before,
.header-cta .btn-amber::before {
  display: none;
}

@keyframes shine {
  0% { left: -100%; }
  15% { left: 100%; }
  100% { left: 100%; }
}

.btn-primary {
  background: linear-gradient(135deg, #2E5BD8 0%, #1F42AA 100%);
  color: white;
  box-shadow: 0 4px 16px rgba(41, 82, 200, 0.25), 0 2px 4px rgba(41, 82, 200, 0.1);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #3663E0 0%, #1F42AA 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(41, 82, 200, 0.35), 0 4px 8px rgba(41, 82, 200, 0.15);
}

.btn-primary:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(41, 82, 200, 0.2);
}

.btn-secondary {
  background: var(--bg-white);
  color: var(--text-primary);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-xs);
}

.btn-secondary:hover {
  background: var(--bg-light);
  border-color: var(--primary);
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}

.btn-amber {
  background: linear-gradient(135deg, #D97706 0%, #B45309 100%);
  color: white;
  box-shadow: 0 4px 16px rgba(146, 64, 14, 0.22), 0 2px 4px rgba(146, 64, 14, 0.1);
}

.btn-amber:hover {
  background: linear-gradient(135deg, #E08C16 0%, #9A4708 100%);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(146, 64, 14, 0.3), 0 4px 8px rgba(146, 64, 14, 0.15);
}

.btn-amber:active {
  transform: translateY(0);
  box-shadow: 0 2px 8px rgba(146, 64, 14, 0.2);
}

.btn-block {
  display: block;
  text-align: center;
  width: 100%;
}

/* ========================================
   Header
   ======================================== */
header#header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(203, 213, 225, 0.78);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.045);
  transition: all var(--transition-base);
}

header#header.scrolled {
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08), 0 1px 0 rgba(203, 213, 225, 0.8);
  background: rgba(255, 255, 255, 0.98);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 80px;
}

.logo {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 12px;
  text-decoration: none;
  transition: transform var(--transition-fast);
}

.logo:hover { transform: translateY(-1px); }

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

.logo-icon {
  width: 40px;
  height: 40px;
}

.logo-text {
  font-family: 'Sora', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: -0.02em;
}

.nav-links {
  display: flex;
  align-items: center;
  flex: 0 1 auto;
  gap: 36px;
}

.nav-links a {
  flex: 0 0 auto;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  white-space: nowrap;
  transition: all var(--transition-fast);
  position: relative;
  padding: 4px 0;
}

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

.nav-links a:hover { color: var(--primary); }
.nav-links a:hover::after { width: 100%; }

.header-cta {
  display: flex;
  align-items: center;
  flex: 0 0 auto;
  gap: 16px;
}

.header-cta .btn {
  flex: 0 0 auto;
  white-space: nowrap;
}

/* ========================================
   Hamburger Button
   ======================================== */
.hamburger-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  border-radius: 6px;
  transition: background var(--transition-base);
}

.hamburger-btn:hover { background: var(--gray-100); }

.hamburger-btn span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform 0.3s ease, opacity 0.3s ease;
  transform-origin: center;
}

.hamburger-btn.is-active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger-btn.is-active span:nth-child(2) { opacity: 0; }
.hamburger-btn.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ========================================
   Mobile Menu
   ======================================== */
.mobile-menu-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 998;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.mobile-menu-overlay.is-active {
  display: block;
  opacity: 1;
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  width: 280px;
  height: 100%;
  background: #fff;
  z-index: 999;
  padding: 80px 24px 32px;
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.12);
  transform: translateX(100%);
  transition: transform 0.3s ease;
  overflow-y: auto;
}

.mobile-menu.is-active { transform: translateX(0); }

.mobile-nav-links {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-bottom: 32px;
}

.mobile-nav-links a {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-primary);
  padding: 14px 0;
  border-bottom: 1px solid var(--gray-100);
  text-decoration: none;
  transition: color var(--transition-base);
}

.mobile-nav-links a:hover { color: var(--primary); }

.mobile-menu-cta {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

@media (max-width: 1120px) and (min-width: 1025px) {
  .header-inner { gap: 20px; }

  .nav-links { gap: 22px; }

  .header-cta { gap: 10px; }

  .header-cta .btn {
    padding: 12px 18px;
  }
}

@media (max-width: 1024px) {
  .nav-links { display: none; }
  .hamburger-btn { display: flex; }
  .header-cta { display: none; }
}

/* ========================================
   Footer (全ページ共通の深い青フッター)
   ======================================== */
footer {
  padding: 56px 0 32px;
  background: #132449;
  color: rgba(255, 255, 255, 0.75);
}

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

.footer-brand .logo {
  margin-bottom: 18px;
}

.footer-brand .logo-img {
  height: 32px;
}

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

.footer-description {
  font-size: 14px;
  line-height: 1.9;
  color: rgba(255, 255, 255, 0.75);
  max-width: 340px;
}

.footer-heading {
  font-family: 'Sora', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.6);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  margin-bottom: 18px;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 12px;
}

.footer-links a {
  font-size: 14px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.footer-links a:hover {
  color: #FFFFFF;
}

.footer-bottom {
  padding-top: 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-copyright {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
}

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

.footer-legal a {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.footer-legal a:hover { color: #FFFFFF; }

@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
    margin-bottom: 28px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 12px;
    align-items: flex-start;
  }
}
