/* ================================================
   近代政党勉強会 - カスタムスタイル
   カラーパレット: 白・山吹色・赤・紫がかった紺色
   ================================================ */

/* 基本リセット */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

/* スクロールバーのカスタマイズ */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: #f0f2f5;
}

::-webkit-scrollbar-thumb {
  background: #2d3a6e;
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: #3d4f8f;
}

/* セレクションカラー（山吹色） */
::selection {
  background: rgba(245, 166, 35, 0.3);
  color: #1a1a2e;
}

/* フォーカスリングのカスタマイズ */
:focus-visible {
  outline: 2px solid #f5a623;
  outline-offset: 2px;
}

/* スムーズなフォントレンダリング */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* 背景画像のフォールバック */
.hero-section {
  background-color: #2d3a6e;
}

/* 画像読み込み前のプレースホルダー */
[class*="bg-[url"] {
  background-color: #f0f2f5;
}

/* スクロールアニメーション初期状態 */
section > .container {
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

/* レスポンシブ画像 */
img {
  max-width: 100%;
  height: auto;
}

/* リンクのベーススタイル */
a {
  color: inherit;
  text-decoration: none;
}

/* ユーティリティクラス */

/* 山吹色グロー */
.glow-yamabuki {
  box-shadow: 0 0 20px rgba(245, 166, 35, 0.4),
              0 0 40px rgba(245, 166, 35, 0.2),
              0 0 60px rgba(245, 166, 35, 0.1);
}

/* 紺色グロー */
.glow-navy {
  box-shadow: 0 0 20px rgba(45, 58, 110, 0.4),
              0 0 40px rgba(45, 58, 110, 0.2),
              0 0 60px rgba(45, 58, 110, 0.1);
}

/* 赤グロー */
.glow-red {
  box-shadow: 0 0 20px rgba(196, 30, 58, 0.4),
              0 0 40px rgba(196, 30, 58, 0.2),
              0 0 60px rgba(196, 30, 58, 0.1);
}

/* テキストグラデーション対応 */
.text-gradient {
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ガラスモーフィズム効果（ライトテーマ用） */
.glass {
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(45, 58, 110, 0.1);
}

/* アニメーション強化 */
@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

.shimmer {
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(245, 166, 35, 0.3) 50%,
    transparent 100%
  );
  background-size: 200% 100%;
  animation: shimmer 3s infinite;
}

/* ホバー時のカード浮上効果 */
.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(45, 58, 110, 0.15);
}

/* レスポンシブ調整 */
@media (max-width: 768px) {
  html {
    font-size: 14px;
  }

  /* タッチデバイスでのホバー効果を軽減 */
  @media (hover: none) {
    .hover-lift:hover {
      transform: none;
      box-shadow: none;
    }
  }
}

/* プリント用スタイル */
@media print {
  body {
    background: white;
    color: black;
  }

  section {
    page-break-inside: avoid;
  }

  .glow-yamabuki,
  .glow-navy,
  .glow-red {
    box-shadow: none;
  }
}

/* 高コントラストモード対応 */
@media (prefers-contrast: high) {
  :root {
    --text-dark: #000000;
    --text-gray: #333333;
  }
}

/* アニメーション軽減設定への対応 */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  html {
    scroll-behavior: auto;
  }
}
