/* テーマ標準ヘッダー・フッターを非表示 */
header.wp-block-template-part,
footer.wp-block-template-part {
  display: none !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

:root {
  --mx-bg: #f5f0e8;
  --mx-surface: #fdfaf4;
  --mx-ink: #1a1008;
  --mx-muted: #5c4a2a;
  --mx-brand: #8b2020;
  --mx-brand-dark: #5c1010;
  --mx-accent: #c9a227;
  --mx-accent2: #2d6e3e;
  --mx-border: #d4c4a8;
  --mx-shadow: 0 12px 36px rgba(26, 16, 8, 0.12);
}

html {
  scroll-behavior: smooth;
}

body {
  background:
    radial-gradient(circle at 10% 0%, rgba(201, 162, 39, 0.08), transparent 36%),
    radial-gradient(circle at 90% 10%, rgba(139, 32, 32, 0.07), transparent 40%),
    var(--mx-bg);
  color: var(--mx-ink);
  font-family: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", sans-serif;
  line-height: 1.75;
  padding-top: 90px;
}

h1,
h2,
h3,
h4 {
  font-family: "Noto Serif JP", "Hiragino Mincho ProN", serif;
  letter-spacing: 0.02em;
  line-height: 1.28;
}

.wp-site-blocks {
  gap: 0;
}

.wp-block-group,
.wp-block-columns,
.wp-block-cover,
.wp-block-media-text {
  margin-top: clamp(20px, 3vw, 42px);
  margin-bottom: clamp(20px, 3vw, 42px);
}

.mx-global-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 1000;
  backdrop-filter: blur(10px);
  background: rgba(253, 250, 244, 0.96);
  border-bottom: 2px solid var(--mx-brand);
}

.mx-header-inner {
  max-width: 1160px;
  margin: 0 auto;
  min-height: 72px;
  padding: 10px 18px;
  display: grid;
  align-items: center;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 12px;
}

.mx-brand {
  text-decoration: none;
  color: inherit;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.mx-brand-logo {
  height: 40px;
  width: auto;
  display: block;
  object-fit: contain;
}

.mx-brand-ja {
  font-family: "Noto Serif JP", serif;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--mx-brand-dark);
}

.mx-brand-en {
  font-size: 0.875rem;
  color: var(--mx-muted);
}

.mx-nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: clamp(4px, 0.8vw, 10px);
  margin: 0;
  padding: 0;
  flex-wrap: nowrap;
  justify-content: center;
}

.mx-nav a {
  text-decoration: none;
  color: var(--mx-ink);
  font-size: clamp(0.68rem, 0.95vw, 0.85rem);
  font-weight: 500;
  border-bottom: 2px solid transparent;
  padding: 4px 1px;
  white-space: nowrap;
}

.mx-nav .is-active a,
.mx-nav a:hover {
  color: var(--mx-brand);
  border-bottom-color: var(--mx-accent);
}

.mx-cta,
.mx-button {
  text-decoration: none;
  border-radius: 999px;
  padding: 10px 16px;
  font-weight: 700;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}

.mx-cta {
  color: #fff;
  background: linear-gradient(135deg, var(--mx-accent), var(--mx-brand));
  white-space: nowrap;
}

.mx-cta:hover,
.mx-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(139, 32, 32, 0.28);
}

.mx-hero {
  max-width: 1160px;
  margin: clamp(18px, 3vw, 42px) auto;
  padding: clamp(30px, 5vw, 60px);
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: clamp(18px, 3vw, 34px);
  position: relative;
  overflow: hidden;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.8);
  box-shadow: var(--mx-shadow);
  background: linear-gradient(135deg, #fdfaf4 60%, #f5ece0);
}

.mx-hero-bg {
  position: absolute;
  inset: -15% -20% auto auto;
  width: min(420px, 48vw);
  height: min(420px, 48vw);
  background: radial-gradient(circle, rgba(201, 162, 39, 0.18), rgba(139, 32, 32, 0));
  pointer-events: none;
}

.mx-hero-content {
  max-width: 760px;
  position: relative;
  z-index: 2;
}

.mx-kicker {
  margin: 0 0 10px;
  color: var(--mx-accent);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.mx-hero h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 3.4rem);
  color: var(--mx-brand-dark);
}

.mx-lead {
  margin: 18px 0 24px;
  color: var(--mx-muted);
  font-size: clamp(1rem, 2.2vw, 1.14rem);
}

.mx-hero-points {
  margin: 0 0 20px;
  padding-left: 1.1em;
}

.mx-hero-points li {
  margin-bottom: 8px;
}

.mx-hero-media {
  border-radius: 20px;
  min-height: 280px;
  background-size: cover;
  background-position: center;
  border: 1px solid rgba(139, 32, 32, 0.15);
  box-shadow: inset 0 -60px 120px rgba(92, 16, 16, 0.18);
}

.mx-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.mx-button.primary {
  background: linear-gradient(135deg, var(--mx-brand), var(--mx-brand-dark));
  color: #fff;
}

.mx-button.ghost {
  border: 1px solid var(--mx-border);
  color: var(--mx-brand);
  background: rgba(253, 250, 244, 0.9);
}

.mx-service-cards,
.mx-trust {
  max-width: 1160px;
  margin: clamp(24px, 4vw, 52px) auto;
  padding: clamp(22px, 4vw, 40px);
  border-radius: 24px;
  background: var(--mx-surface);
  border: 1px solid var(--mx-border);
  box-shadow: var(--mx-shadow);
}

.mx-service-cards h2,
.mx-trust h2 {
  margin-top: 0;
  margin-bottom: 8px;
  color: var(--mx-brand-dark);
}

.mx-service-intro {
  margin-top: 0;
  margin-bottom: 20px;
  color: var(--mx-muted);
}

.mx-card-grid {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.mx-card {
  border: 1px solid var(--mx-border);
  border-radius: 18px;
  padding: 20px;
  background: #fff;
  border-top: 3px solid var(--mx-accent);
}

.mx-card h3 {
  margin-top: 0;
  margin-bottom: 8px;
  font-size: 1.2rem;
  color: var(--mx-brand-dark);
}

.mx-card p {
  margin-top: 0;
  color: var(--mx-muted);
}

.mx-card-meta {
  margin: 0 0 12px;
  font-size: 0.9rem;
  color: var(--mx-muted);
  border-left: 3px solid var(--mx-accent2);
  padding-left: 10px;
}

.mx-card a {
  color: var(--mx-brand);
  font-weight: 700;
  text-decoration-color: rgba(26, 79, 160, 0.3);
}

.mx-track-cta {
  position: relative;
}

.mx-track-cta::after {
  content: "";
  position: absolute;
  inset: auto 8px -2px;
  height: 2px;
  background: linear-gradient(90deg, var(--mx-accent), transparent);
  opacity: 0;
  transition: opacity 0.25s ease;
}

.mx-track-cta:hover::after {
  opacity: 1;
}

.mx-trust ul {
  margin: 0;
  padding-left: 1.1em;
}

.mx-trust li {
  margin-bottom: 8px;
}

.mx-trust-links {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.mx-trust-links a {
  text-decoration: none;
  border: 1px solid var(--mx-border);
  color: var(--mx-brand);
  background: #fff;
  border-radius: 999px;
  padding: 8px 13px;
}

.mx-contact-anchor {
  position: relative;
  top: -90px;
}

.mx-footer-band {
  margin-top: clamp(36px, 7vw, 82px);
  border-top: 3px solid var(--mx-brand);
  background: linear-gradient(135deg, #2a1a08, #4a2010);
  color: #fff;
}

.mx-footer-inner {
  max-width: 1160px;
  margin: 0 auto;
  padding: clamp(24px, 4vw, 40px) 18px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.mx-footer-col h2,
.mx-footer-col h3 {
  margin-top: 0;
  margin-bottom: 10px;
  color: #fff;
}

.mx-footer-col p {
  margin-top: 0;
  color: rgba(255, 255, 255, 0.75);
}

.mx-footer-col ul {
  margin: 0;
  padding-left: 1.1em;
}

.mx-footer-col a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
}

.mx-footer-col a:hover {
  color: var(--mx-accent);
}

.mx-footer-col .mx-button.primary {
  background: linear-gradient(135deg, var(--mx-accent), #a07d10);
  color: #fff;
}

.page-id-38 h1,
.page-id-38 .entry-title,
.page-id-38 .wp-block-heading {
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.page-id-38 ul {
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  padding-left: clamp(80px, 12vw, 160px);
}

.page-id-38 .wpcf7 {
  max-width: 900px;
  margin: 0 auto;
  padding: clamp(18px, 3vw, 30px);
  border-radius: 18px;
  border: 1px solid var(--mx-border);
  background: #fff;
  box-shadow: var(--mx-shadow);
}

.page-id-38 .wpcf7 form > p,
.page-id-38 .wpcf7 .wpcf7-form-control-wrap,
.page-id-38 .wpcf7 label {
  display: block;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.page-id-38 .wpcf7 label {
  font-weight: 700;
  color: var(--mx-brand-dark);
}

.page-id-38 .wpcf7 input[type="text"],
.page-id-38 .wpcf7 input[type="email"],
.page-id-38 .wpcf7 input[type="tel"],
.page-id-38 .wpcf7 select,
.page-id-38 .wpcf7 textarea {
  border-radius: 10px;
  border: 1px solid var(--mx-border);
  background: #fdf8f0;
  padding: 12px;
  width: 100%;
  box-sizing: border-box;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.page-id-38 .wpcf7 input:focus,
.page-id-38 .wpcf7 select:focus,
.page-id-38 .wpcf7 textarea:focus {
  outline: none;
  border-color: var(--mx-accent);
  box-shadow: 0 0 0 3px rgba(201, 162, 39, 0.20);
}

.page-id-38 .wpcf7 input[type="submit"] {
  border: none;
  border-radius: 999px;
  padding: 12px 24px;
  background: linear-gradient(135deg, var(--mx-brand), var(--mx-brand-dark));
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

.page-id-38 .wpcf7 .wpcf7-not-valid-tip {
  color: #b91c1c;
  font-size: 0.87rem;
}

.page-id-38 .wpcf7 form .wpcf7-response-output {
  margin: 14px 0 0;
  border-radius: 10px;
  padding: 10px 12px;
}

/* ── ステップフロー ── */
.mx-step-flow {
  max-width: 760px;
  margin: clamp(24px, 4vw, 52px) auto;
  padding: 0 18px;
}

.mx-step-flow__heading {
  text-align: center;
  color: var(--mx-brand-dark);
  margin-bottom: clamp(24px, 4vw, 40px);
}

.mx-step-flow__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.mx-step-flow__item {
  display: flex;
  align-items: stretch;
  gap: 20px;
  position: relative;
}

/* 矢羽根の縦線（最後以外）— Stepバッジ下からアイテム下端の少し手前まで */
.mx-step-flow__item:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 39px;
  top: 60px;
  bottom: -22px;
  width: 2px;
  background: linear-gradient(to bottom, var(--mx-accent), transparent);
}

/* 矢印三角（最後以外）— Stepラベルに重ならないよう間隙の中央に配置 */
.mx-step-flow__item:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 31px;
  bottom: -10px;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-top: 14px solid var(--mx-accent);
  z-index: 1;
}

.mx-step-flow__badge {
  flex-shrink: 0;
  width: 80px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--mx-brand), var(--mx-brand-dark));
  color: #fff;
  font-weight: 700;
  font-size: 0.88rem;
  border-radius: 10px;
  letter-spacing: 0.05em;
  margin-bottom: 36px;
}

.mx-step-flow__body {
  flex: 1;
  background: var(--mx-surface);
  border: 1px solid var(--mx-border);
  border-left: 4px solid var(--mx-accent);
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 36px;
  box-shadow: var(--mx-shadow);
}

.mx-step-flow__title {
  margin: 0 0 6px;
  font-size: 1.1rem;
  color: var(--mx-brand-dark);
}

.mx-step-flow__desc {
  margin: 0;
  color: var(--mx-muted);
  font-size: 0.95rem;
}

/* 段階的な導入〜お問い合わせ セクション センタリング */
.mx-temple-center {
  max-width: 860px;
  margin: clamp(8px, 1.2vw, 16px) auto clamp(32px, 5vw, 60px);
  padding: 0 18px;
  text-align: center;
}

/* タイトル直上の余白を狭く（特集ページのH1） */
.mx-temple-center > h1:first-child,
.mx-temple-center .wp-block-post-title,
.mx-temple-center :where(h1):first-of-type {
  margin-top: 0;
}

/* 句読点での改行を優先（語中での折り返しを抑制） */
.mx-temple-center p,
.mx-temple-center li,
.mx-temple-center td,
.mx-temple-center th {
  word-break: keep-all;
  overflow-wrap: break-word;
  line-break: strict;
}

/* タイトル上部の余白を縮める（特集ページ） */
.page-id-272 main.wp-block-group,
.page-id-276 main.wp-block-group,
.page-id-281 main.wp-block-group {
  margin-top: clamp(8px, 1.5vw, 18px) !important;
}

.page-id-272 .wp-block-post-title,
.page-id-276 .wp-block-post-title,
.page-id-281 .wp-block-post-title {
  margin-top: 0 !important;
  padding-top: 0 !important;
}

.mx-temple-center .mx-step-flow {
  text-align: left;
  margin: 0 auto clamp(32px, 5vw, 52px);
}

.mx-temple-center h1,
.mx-temple-center h2,
.mx-temple-center h3,
.mx-temple-center h4 {
  color: var(--mx-brand-dark);
}

.mx-temple-center p {
  color: var(--mx-muted);
  margin-left: auto;
  margin-right: auto;
  max-width: 600px;
}

/* 箇条書きは左揃えブロックをページ中央に配置 */
.mx-temple-center ul {
  display: inline-block;
  text-align: left;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.4em;
  max-width: 600px;
  width: 100%;
}

.mx-temple-center ul li {
  margin-bottom: 6px;
  color: var(--mx-muted);
}

.mx-temple-center a {
  display: inline-block;
  margin-top: 8px;
  color: #fff;
  background: linear-gradient(135deg, var(--mx-brand), var(--mx-brand-dark));
  border-radius: 999px;
  padding: 12px 28px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.mx-temple-center a:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(139, 32, 32, 0.28);
}

/* ── 機能一覧テーブル ── */
.mx-feature-table,
.mx-plan-table {
  width: 100%;
  max-width: 800px;
  margin: 0 auto clamp(24px, 4vw, 40px);
  border-collapse: collapse;
  text-align: left;
  font-size: 0.95rem;
  box-shadow: var(--mx-shadow);
  border-radius: 12px;
  overflow: hidden;
}

.mx-feature-table thead,
.mx-plan-table thead {
  background: linear-gradient(135deg, var(--mx-brand), var(--mx-brand-dark));
  color: #fff;
}

.mx-feature-table thead th,
.mx-plan-table thead th {
  padding: 12px 16px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.mx-feature-table tbody tr,
.mx-plan-table tbody tr {
  border-bottom: 1px solid var(--mx-border);
  background: var(--mx-surface);
  transition: background 0.2s ease;
}

.mx-feature-table tbody tr:last-child,
.mx-plan-table tbody tr:last-child {
  border-bottom: none;
}

.mx-feature-table tbody tr:hover,
.mx-plan-table tbody tr:hover {
  background: #fdf7f0;
}

.mx-feature-table td,
.mx-plan-table td {
  padding: 12px 16px;
  color: var(--mx-muted);
  vertical-align: top;
}

.mx-feature-table td:first-child,
.mx-plan-table td:first-child {
  color: var(--mx-brand-dark);
  white-space: nowrap;
  width: 30%;
}

/* 料金プランの月額列 */
.mx-plan-table td:nth-child(2) {
  white-space: nowrap;
  color: var(--mx-brand);
  font-weight: 700;
  width: 26%;
}

/* 料金プラン補助見出し（オプション・個別対応） */
.mx-plan-subheading {
  max-width: 800px;
  margin: clamp(20px, 3vw, 32px) auto 12px;
  text-align: left;
  color: var(--mx-brand-dark);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

/* オプション表は月額列の強調を控えめに */
.mx-plan-table--option td:nth-child(2) {
  color: var(--mx-muted);
  font-weight: 600;
  white-space: normal;
}

/* 料金プラン補足注記 */
.mx-plan-note {
  max-width: 800px;
  margin: 8px auto 0;
  font-size: 0.85rem;
  color: var(--mx-muted);
  text-align: left;
}

/* 4列以上のプラン表ではプラン名列の幅を抑える */
.mx-plan-table thead tr:has(th:nth-child(4)) ~ * td:first-child,
.mx-plan-table:has(thead th:nth-child(4)) td:first-child {
  width: 18%;
}

/* columbarium ページ固有のスタイル調整 */
.mx-columbarium .mx-step-flow {
  text-align: left;
}

.mx-columbarium h1,
.mx-columbarium h2 {
  color: var(--mx-brand-dark);
}

.mx-columbarium .service-section {
  margin-bottom: clamp(28px, 5vw, 52px);
}

.mx-columbarium .service-cta {
  margin-top: clamp(28px, 5vw, 52px);
}

.mx-columbarium .service-cta a,
.mx-columbarium .service-button {
  display: inline-block;
  margin-top: 8px;
  color: #fff;
  background: linear-gradient(135deg, var(--mx-brand), var(--mx-brand-dark));
  border-radius: 999px;
  padding: 12px 28px;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.mx-columbarium .service-cta a:hover,
.mx-columbarium .service-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(139, 32, 32, 0.28);
}

@media (max-width: 620px) {
  .mx-step-flow__badge {
    width: 64px;
    height: 48px;
    font-size: 0.875rem;
  }

  .mx-step-flow__item:not(:last-child)::after {
    left: 31px;
  }

  .mx-step-flow__item:not(:last-child)::before {
    left: 23px;
  }
}

.reveal-on-scroll {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}

.reveal-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}


@media (max-width: 980px) {
  body {
    padding-top: 112px;
  }

  .mx-header-inner {
    grid-template-columns: 1fr;
    gap: 8px;
    padding-top: 10px;
    padding-bottom: 12px;
  }

  .mx-nav ul {
    gap: 10px;
  }

  .mx-card-grid {
    grid-template-columns: 1fr;
  }

  .mx-hero {
    grid-template-columns: 1fr;
    border-radius: 20px;
  }

  .mx-hero-media {
    min-height: 220px;
  }

  .mx-footer-inner {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 620px) {
  body {
    padding-top: 138px;
  }

  .mx-nav a {
    font-size: 0.86rem;
  }

  .mx-cta,
  .mx-button {
    width: 100%;
    text-align: center;
  }

  .mx-hero-actions {
    gap: 8px;
  }

  .mx-footer-inner {
    grid-template-columns: 1fr;
  }
}

