/*
Theme Name: AI Days
Theme URI: https://aidays.jp
Description: 働く女性・ママ・フリーランスのためのAI活用メディア用WordPressテーマ。ピンク×パープルのグラデーション、ラメ効果、女性向けUI/UX最適化、アフィリエイト管理、アナリティクスダッシュボード完備。
Author: AI Days Team
Author URI: https://aidays.jp
Version: 2.0.0
License: GPL v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: aidays
Tags: blog, custom-colors, custom-menu, editor-style, featured-images, flexible-header, custom-logo, translation-ready, responsive-layout, ai, women, pink, purple
*/

/* ===================================
   CSS Variables - AI Days カラーシステム（nokurashi風）
   =================================== */
:root {
  /* メインカラー - nokurashi風：ベージュ×ブラック */
  --brand-primary: #2a2622;      /* ダークブラウン（メイン） */
  --brand-secondary: #c9b8a8;    /* ウォームベージュ（アクセント） */
  --brand-tertiary: #a69186;     /* グレージュ */
  --brand-light: #f5f0eb;        /* クリームベージュ */
  --brand-muted: #8d8780;        /* ミューテッドグレー */

  /* 拡張カラー - 自然で落ち着いた配色 */
  --soft-beige: #f0e6dc;         /* ソフトベージュ */
  --warm-cream: #faf7f3;         /* ウォームクリーム */
  --warm-beige: #e8dfd5;         /* 温かみのあるベージュ */
  --dusty-brown: #b0a099;        /* ダスティブラウン */
  --sage-green: #b5c4a9;         /* セージグリーン（アクセント用） */

  /* グラデーション - 控えめで自然に */
  --gradient-main: linear-gradient(135deg, #f5f0eb 0%, #e8dfd5 100%);
  --gradient-soft: linear-gradient(135deg, #faf7f3 0%, #f0e6dc 100%);
  --gradient-overlay: linear-gradient(135deg, rgba(245, 240, 235, 0.95) 0%, rgba(232, 223, 213, 0.95) 100%);
  --gradient-warm: linear-gradient(135deg, #f0e6dc 0%, #e8dfd5 100%);

  /* カテゴリカラー - 自然なアースカラー */
  --color-working-women: #b0a099;  /* ダスティブラウン */
  --color-moms: #c9b8a8;           /* ウォームベージュ */
  --color-freelance: #b5c4a9;      /* セージグリーン */
  --color-sidejob: #d4a574;        /* テラコッタベージュ */
  --color-office-work: #8fa7b8;    /* ダスティブルー */
  --color-beginner: #a69186;       /* グレージュ */

  /* UI カラー - 自然で柔らかいトーン */
  --success: #b5c4a9;    /* セージグリーン */
  --warning: #d4a574;    /* テラコッタ */
  --error: #c67b7b;      /* ソフトレッド */
  --info: #8fa7b8;       /* ダスティブルー */

  /* AI用アクセントカラー - テクノロジー感を自然に表現 */
  --ai-accent: #7ba8c4;       /* ソフトブルー（AIらしさ） */
  --ai-accent-light: #a8c9db; /* ライトブルー */
  --ai-accent-soft: #e8f2f7;  /* 非常に淡いブルー */
  --ai-glow: rgba(123, 168, 196, 0.15); /* グロー効果用 */

  /* ニュートラルカラー - 温かみのあるグレー */
  --white: #ffffff;
  --off-white: #fafaf8;
  --black: #2a2622;
  --gray-50: #faf7f3;
  --gray-100: #f5f0eb;
  --gray-200: #e8dfd5;
  --gray-300: #d1cec8;
  --gray-400: #b0aca5;
  --gray-500: #8d8780;
  --gray-600: #6d6860;
  --gray-700: #544f48;
  --gray-800: #3d3935;
  --gray-900: #2a2622;

  /* タイポグラフィ - 女性向け優しいフォント */
  --font-base: 'Zen Maru Gothic', 'M PLUS Rounded 1c', -apple-system, BlinkMacSystemFont, 'Hiragino Sans', sans-serif;
  --font-heading: 'M PLUS Rounded 1c', 'Zen Maru Gothic', -apple-system, BlinkMacSystemFont, sans-serif;

  /* サイズ */
  --text-xs: 0.75rem;    /* 12px */
  --text-sm: 0.875rem;   /* 14px */
  --text-base: 1rem;     /* 16px */
  --text-lg: 1.125rem;   /* 18px */
  --text-xl: 1.25rem;    /* 20px */
  --text-2xl: 1.5rem;    /* 24px */
  --text-3xl: 1.875rem;  /* 30px */
  --text-4xl: 2.25rem;   /* 36px */

  /* スペーシング */
  --space-1: 0.25rem;   /* 4px */
  --space-2: 0.5rem;    /* 8px */
  --space-3: 0.75rem;   /* 12px */
  --space-4: 1rem;      /* 16px */
  --space-5: 1.25rem;   /* 20px */
  --space-6: 1.5rem;    /* 24px */
  --space-8: 2rem;      /* 32px */
  --space-10: 2.5rem;   /* 40px */
  --space-12: 3rem;     /* 48px */
  --space-16: 4rem;     /* 64px */
  --space-20: 5rem;     /* 80px */

  /* ボーダーRadius */
  --radius-sm: 0.375rem;  /* 6px */
  --radius-md: 0.5rem;    /* 8px */
  --radius-lg: 1rem;      /* 16px */
  --radius-xl: 1.5rem;    /* 24px */
  --radius-full: 9999px;

  /* シャドウ - 自然な影 */
  --shadow-sm: 0 1px 2px 0 rgba(61, 57, 53, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(61, 57, 53, 0.08), 0 2px 4px -1px rgba(61, 57, 53, 0.04);
  --shadow-lg: 0 10px 15px -3px rgba(61, 57, 53, 0.1), 0 4px 6px -2px rgba(61, 57, 53, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(61, 57, 53, 0.12), 0 10px 10px -5px rgba(61, 57, 53, 0.04);
  --shadow-soft: 0 4px 20px rgba(212, 165, 165, 0.15);

  /* トランジション */
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);

  /* Z-index */
  --z-dropdown: 1000;
  --z-sticky: 1020;
  --z-fixed: 1030;
  --z-modal: 1040;
  --z-popover: 1050;
  --z-tooltip: 1060;
}

/* ===================================
   リセット & ベーススタイル
   =================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-base);
  font-size: var(--text-base);
  line-height: 1.9;
  color: var(--gray-800);
  background: var(--gray-50); /* ウォームクリーム背景 */
  overflow-x: hidden;
  font-weight: 400;
  letter-spacing: 0.02em;
}

/* カスタムスクロールバー - グラデーション */
::-webkit-scrollbar {
  width: 12px;
  height: 12px;
}

::-webkit-scrollbar-track {
  background: var(--gray-100);
}

::-webkit-scrollbar-thumb {
  background: var(--gradient-main);
  border-radius: var(--radius-full);
  border: 2px solid var(--gray-100);
}

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

/* 選択テキスト */
::selection {
  background: var(--ai-accent-soft);
  color: var(--gray-900);
}

::-moz-selection {
  background: var(--ai-accent-soft);
  color: var(--gray-900);
}

/* ===================================
   タイポグラフィ
   =================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 500;
  line-height: 1.6;
  color: var(--gray-900);
  margin-bottom: var(--space-4);
  letter-spacing: 0.03em;
}

h1 { font-size: var(--text-4xl); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-2xl); }
h4 { font-size: var(--text-xl); }
h5 { font-size: var(--text-lg); }
h6 { font-size: var(--text-base); }

p {
  margin-bottom: var(--space-4);
  line-height: 2;
}

a {
  color: var(--brand-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--ai-accent);
}

strong, b {
  font-weight: 700;
}

em, i {
  font-style: italic;
}

/* ===================================
   レイアウト - nokurashi風のゆったりした余白
   =================================== */
.container {
  max-width: 1140px; /* nokurashi風：少し狭めでゆとりある */
  margin: 0 auto;
  padding: 0 var(--space-6);
}

@media (min-width: 768px) {
  .container {
    padding: 0 var(--space-10);
  }
}

@media (min-width: 1024px) {
  .container {
    padding: 0 var(--space-16);
  }
}

/* ===================================
   ボタン
   =================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  font-size: var(--text-base);
  font-weight: 600;
  text-align: center;
  border: none;
  border-radius: var(--radius-xl);
  cursor: pointer;
  transition: all var(--transition-base);
  text-decoration: none;
  min-height: 48px; /* モバイルタップ領域 */
  box-shadow: var(--shadow-sm);
}

.btn-primary {
  background: var(--black);
  color: var(--white);
  border-radius: var(--radius-full); /* 完全な丸みボタン */
  font-weight: 500;
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, var(--ai-glow), transparent);
  transition: left 0.5s;
}

.btn-primary:hover::before {
  left: 100%;
}

.btn-primary:hover {
  background: var(--gray-800);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px var(--ai-glow), var(--shadow-md);
}

.btn-outline {
  background: transparent;
  color: var(--black);
  border: 2px solid var(--black);
  border-radius: var(--radius-full);
}

.btn-outline:hover {
  background: var(--black);
  color: var(--white);
  border-color: var(--black);
  transform: translateY(-1px);
}

.btn-lg {
  padding: var(--space-4) var(--space-8);
  font-size: var(--text-lg);
  min-height: 56px;
}

.btn-sm {
  padding: var(--space-2) var(--space-4);
  font-size: var(--text-sm);
  min-height: 40px;
}

/* ===================================
   カード - nokurashi風シンプルデザイン
   =================================== */
.card {
  background: var(--white);
  border-radius: var(--radius-md);
  padding: var(--space-8);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
  transition: all var(--transition-base);
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08), 0 0 20px var(--ai-glow);
  border: 1px solid var(--ai-accent-soft);
}

.card-header {
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-4);
}

.card-title {
  font-size: var(--text-xl);
  font-weight: 700;
  color: var(--gray-900);
  margin: 0;
}

.card-body {
  margin-bottom: var(--space-4);
}

.card-footer {
  margin-top: var(--space-4);
  padding-top: var(--space-4);
}

/* ===================================
   バッジ
   =================================== */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-3);
  font-size: var(--text-xs);
  font-weight: 600;
  border-radius: var(--radius-full);
  white-space: nowrap;
}

.badge-ai {
  background: var(--ai-accent-soft);
  color: var(--ai-accent);
}

.badge-accent {
  background: var(--ai-accent-light);
  color: var(--brand-primary);
}

.badge-success {
  background: #d1fae5;
  color: #065f46;
}

.badge-warning {
  background: #fef3c7;
  color: #92400e;
}

.badge-info {
  background: #dbeafe;
  color: #1e40af;
}

/* ===================================
   ユーティリティクラス
   =================================== */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-1 { margin-top: var(--space-1); }
.mt-2 { margin-top: var(--space-2); }
.mt-3 { margin-top: var(--space-3); }
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }

.mb-1 { margin-bottom: var(--space-1); }
.mb-2 { margin-bottom: var(--space-2); }
.mb-3 { margin-bottom: var(--space-3); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }

.hidden { display: none; }
.block { display: block; }
.inline-block { display: inline-block; }
.flex { display: flex; }
.inline-flex { display: inline-flex; }

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

  h1 { font-size: var(--text-3xl); }
  h2 { font-size: var(--text-2xl); }
  h3 { font-size: var(--text-xl); }
}

@media (min-width: 1440px) {
  .container {
    max-width: 1400px;
  }
}

/* ===================================
   バナー広告スタイル
   =================================== */
.banner-ad-wrapper {
  margin: var(--space-12) 0;
  text-align: center;
}

.banner-ad-area {
  display: inline-block;
  background: var(--white);
  padding: var(--space-4);
  border-radius: var(--radius-md);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.ad-label {
  display: block;
  font-size: var(--text-xs);
  color: var(--gray-500);
  text-align: center;
  margin-bottom: var(--space-2);
  font-weight: 500;
  letter-spacing: 0.05em;
}

/* バナーサイズバリエーション */
.banner-large .banner-ad-area {
  max-width: 970px;
  width: 100%;
}

.banner-medium .banner-ad-area {
  max-width: 728px;
  width: 100%;
}

.banner-small .banner-ad-area {
  max-width: 468px;
  width: 100%;
}

/* レスポンシブ対応 */
@media (max-width: 767px) {
  .banner-ad-area {
    max-width: 100%;
    padding: var(--space-3);
  }

  .banner-ad-wrapper {
    margin: var(--space-8) 0;
  }
}

/* サイドバー固定バナー */
.banner-sidebar-sticky {
  position: sticky;
  top: var(--space-8);
  margin-bottom: var(--space-6);
}
