/* ==========================================================================
   Variables - サイト共通の定義
   ========================================================================== */

:root {
  /* Colors */
  --color-main: #007cba;
  --color-text: #333;
  --color-text-light: #404040;
  --color-border: #eee;
  --color-bg: rgba(255, 255, 255, 0.75);

  /* Animation */
  --ease-default: cubic-bezier(0.25, 0.8, 0.25, 1);
  --transition-speed: 0.3s;
}

/* ==========================================================================
   Reset & Base - 基本要素の設定
   ========================================================================== */

html {
  box-sizing: border-box;
  line-height: 1.15;
  -webkit-text-size-adjust: 100%; /* iOSのフォントサイズ自動調整防止 */
  scroll-behavior: smooth;
}

*,
*::before,
*::after {
  box-sizing: inherit;
}

body {
  margin: 0;
  padding-top: 80px;
  background: var(--color-bg);
  color: var(--color-text-light);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
}

/* 背景画像の設定（管理画面以外に適用） */
body:not(.wp-admin) {
  background-image: url('../images/background.png') !important;
  background-attachment: fixed !important;
  background-size: cover !important;
  background-position: center !important;
  background-repeat: no-repeat !important;
}

/* レイアウトの基本 */
.site {
  margin-left: 20px;
  margin-right: 20px;
}

/* 記事コンテンツ（透過レイヤー） */
.site-main {
  margin-top: 2rem;
  margin-bottom: 2rem;
  padding: 2rem; /* 余白が必要な場合は調整してください */
  background-color: rgba(255, 255, 255, 0.9);
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

/* メディア要素の基本設定 */
img,
video {
  max-width: 100%;
  height: auto;
  vertical-align: middle;
}

/* ==========================================================================
   Typography - 見出しと本文
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  margin-bottom: 0.5em;
  color: var(--color-text);
  line-height: 1.3;
}

p {
  margin-top: 0;
  margin-bottom: 1em;
}

/* ==========================================================================
   Links - リンク設定
   ========================================================================== */

a {
  color: var(--color-main);
  text-decoration: none;
  transition: color var(--transition-speed) var(--ease-default);
}

a:hover,
a:focus {
  text-decoration: underline;
  outline: none;
}

/* ==========================================================================
   Utility - 汎用クラス
   ========================================================================== */

.container {
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
}

.container-narrow {
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.transition {
  transition: all var(--transition-speed) var(--ease-default);
}

/* 投稿個別スタイル用（将来的な拡張用） */
.post {
  /* margin: 0 auto !important; */
}