/* =========================
   base.css — グローバルリセット + 共通スタイル
   ※ tokens.css を先に読み込むこと。:root 変数定義は tokens.css で行う。
========================= */

/* hidden 属性リセット */
[hidden] { display: none !important; }

/* =========================
   全体ベース
========================= */
body {
  margin: 0;
  color: var(--color-text-primary);
  background: var(--gradient-body);
  background-attachment: fixed;
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.9;
  letter-spacing: 0.04em;
}

/* =========================
   セクション外枠
========================= */
.section {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: var(--section-pad-y) var(--section-pad-x);
  box-sizing: border-box;
}

.section + .section {
  margin-top: var(--section-gap);
}

main > .section:first-child { margin-top: 0; }
main > .section:last-child  { margin-bottom: var(--section-gap); }

/* =========================
   固定背景ラッパー
========================= */
.fixedbg-wrapper {
  position: relative;
  background-image: var(--fixedbg-image, none);
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  background-repeat: no-repeat;
}

.fixedbg-wrapper::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  pointer-events: none;
  z-index: 0;
}

.fixedbg-wrapper > .section {
  position: relative;
  z-index: 1;
}

.section__inner--glass {
  background: var(--gradient-dark);
  backdrop-filter: blur(6px);
}

.section__inner--card {
  background: var(--color-surface-white);
  border-radius: 20px;
  box-shadow: var(--shadow-card);
  border: 1px solid rgba(255, 255, 255, 0.7);
}

/* =========================
   セクション内コンテンツ（標準箱）
========================= */
.section__inner {
  position: relative;
  width: 100%;
  padding: var(--inner-pad);
  box-sizing: border-box;
  border-radius: var(--inner-radius);
}

/* =========================
   セクションタイトル
========================= */
.section-title {
  position: relative;
  top: auto;
  left: auto;
  margin: 0 0 36px;
  padding: 0;
  color: var(--color-brand-primary);
  font-size: var(--text-3xl);
  font-family: var(--font-display);
  letter-spacing: 0.1em;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
}

.section-title::after {
  content: "✦  ✧  ✦";
  display: block;
  font-size: var(--text-2xs);
  letter-spacing: 0.6em;
  color: rgba(192, 80, 112, 0.5);
  margin-top: 4px;
}

/* =========================
   本文テキスト
========================= */
p {
  margin: 0 0 1.6em 0;
  color: var(--color-text-secondary);
}

strong {
  font-weight: 700;
  color: var(--color-text-primary);
  margin: 0 4px;
}

.text-small {
  font-size: var(--text-sm);
  opacity: 0.85;
}

.section__inner p:last-child { margin-bottom: 0; }

/* =========================
   リンク（共通ベース）
========================= */
a {
  color: var(--link-color);
  text-decoration: none;
  transition:
    color var(--transition-base),
    text-shadow var(--transition-base);
}

a:hover {
  color: var(--link-hover);
  text-shadow: 0 0 8px rgba(232, 48, 96, 0.25);
}

.link-text { position: relative; }

.link-text::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 100%;
  height: 1px;
  background: linear-gradient(to right,
    transparent,
    var(--link-hover),
    transparent);
  opacity: 0;
  transition: opacity var(--transition-base);
}

.link-text:hover::after { opacity: 1; }

.link-box {
  transition:
    transform var(--transition-base),
    box-shadow var(--transition-base),
    border-color var(--transition-base);
}

.link-box:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.link-soft:hover {
  color: var(--link-hover-soft);
  text-shadow: none;
}

/* =========================
   デコレーションテキスト
========================= */
.all-text {
  display: block;
  width: 100%;
  font-size: var(--text-sm);
  text-align: center;
  margin-top: 35px;
  color: var(--color-brand-primary);
  letter-spacing: 0.06em;
}

.minititle-text {
  display: block;
  width: 100%;
  font-size: var(--text-lg);
  text-align: center;
  margin-top: 15px;
  color: var(--color-text-secondary);
}

.conjure-box { text-align: center; }

.conjure-text {
  display: inline-block;
  width: auto;
  font-size: var(--text-sm);
  margin-top: 5px;
  color: var(--color-brand-primary);
  background: var(--color-brand-bg);
  border: 1px solid var(--color-brand-border);
  padding: 8px 40px;
  border-radius: var(--radius);
}

.conjure-text:hover {
  text-shadow: none;
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

/* =========================
   conjure お問い合わせCTA（共通ベース）
   テーマはCSSカスタムプロパティで上書き可能
========================= */
.conjure-contact-cta {
  margin-top: 60px;
  padding: 32px 24px;
  text-align: center;
  border-radius: var(--radius-lg);
  background: var(--cta-bg, rgba(255, 233, 241, 0.4));
  border: 1px solid var(--cta-border, var(--color-brand-border));
}

.conjure-contact-text {
  margin-bottom: 20px;
  font-size: var(--text-base);
  color: var(--cta-text-color, var(--color-text-secondary));
  line-height: 1.7;
}

.conjure-contact-button {
  display: inline-block;
  padding: 12px 32px;
  border-radius: var(--radius-full);
  font-size: var(--text-base);
  font-weight: 600;
  letter-spacing: 0.05em;
  color: #fff;
  background: var(--gradient-brand);
  text-decoration: none;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-base), box-shadow var(--transition-base), opacity var(--transition-base);
}

.conjure-contact-button:hover {
  color: #fff;
  text-shadow: none;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  opacity: 0.95;
}

/* =====================================================
   RESPONSIVE TOKEN OVERRIDES
   CSS カスタムプロパティをブレークポイントごとに上書き。
   var() を使っている全コンポーネントが自動追従する。

   bp-tablet-landscape : 1024px
   bp-tablet           :  900px
   bp-phone-lg         :  680px
   bp-phone            :  520px
   bp-phone-sm         :  480px
===================================================== */

/* ── タブレット横（1024px）─────────────────────────── */
@media (max-width: 1024px) { /* bp-tablet-landscape */
  :root {
    --section-pad-x:  80px;
    --section-pad-y:  64px;
    --section-gap:    80px;
    --inner-pad:      48px;

    --text-3xl: 36px;   /* セクションタイトル */
    --text-2xl: 28px;
  }

  /* 白カードのradius、大画面ほど大きくなくていい */
  .section__inner--card { border-radius: 16px; }
}

/* ── タブレット縦（900px）──────────────────────────── */
@media (max-width: 900px) { /* bp-tablet */
  :root {
    --section-pad-x:  40px;
    --section-pad-y:  56px;
    --section-gap:    60px;
    --inner-pad:      32px;

    --text-3xl: 30px;
    --text-2xl: 24px;
    --text-xl:  22px;
  }
}

/* ── 大型スマホ（680px）────────────────────────────── */
@media (max-width: 680px) { /* bp-phone-lg */
  :root {
    --section-pad-x:  16px;
    --section-pad-y:  40px;
    --section-gap:    40px;
    --inner-pad:      20px;

    /* フォントスケール縮小 */
    --text-3xl: 24px;
    --text-2xl: 20px;
    --text-xl:  18px;
    --text-lg:  17px;
    --text-md:  15px;
    --text-base: 14px;
    --text-sm:  12px;
  }

  .section__inner--card {
    border-radius: 12px;
  }

  /* セクションタイトル下マージン縮小 */
  .section-title { margin-bottom: 24px; }
}

/* ── 標準スマホ（520px）────────────────────────────── */
@media (max-width: 520px) { /* bp-phone */
  :root {
    --section-pad-x:  12px;
    --section-pad-y:  32px;
    --section-gap:    32px;
    --inner-pad:      14px;

    --text-3xl: 20px;
    --text-2xl: 18px;
    --text-xl:  16px;
    --text-lg:  15px;
    --text-md:  14px;
    --text-base: 13px;
    --text-sm:  11px;
    --text-xs:  10px;
  }

  .section__inner--card {
    border-radius: 10px;
  }

  .section-title { margin-bottom: 18px; }

  /* CTA ボタンを全幅に近くする */
  .conjure-contact-button {
    display: block;
    width: 100%;
    box-sizing: border-box;
    text-align: center;
  }
}
