/* ========================================
   カスタムスタイル
   registerBlockStyle で登録したカスタムスタイルのCSS
======================================== */

.is-style-tall+.is-style-tall {
  margin-block-start: 70px;
}

.is-style-short+.is-style-short {
  margin-block-start: 50px;
}

@media (max-width: 782px) {
  .is-style-tall+.is-style-tall {
    margin-block-start: 50px;
  }

  .is-style-short+.is-style-short {
    margin-block-start: 30px;
  }
}

/* キャッチコピースタイル（太文字・PC中央寄せ・SP左寄せ） */
.is-style-catch {
  text-align: center;
  font-weight: bold;
}

@media (max-width: 800px) {
  .is-style-catch {
    text-align: left !important;
  }
}

/* モバイル用配置スタイル */
@media (max-width: 800px) {
  .is-style-sp-center {
    text-align: center !important;
  }

  .is-style-sp-left {
    text-align: left !important;
  }

  .is-style-sp-right {
    text-align: right !important;
  }
}


/* 見出しスタイル */
.is-style-title-h2 {
  font-size: 30px;
  position: relative;
  padding-bottom: 20px;
  margin-bottom: 50px;
}

.is-style-title-h2::before {
  content: "";
  background: var(--wp--preset--color--primary);
  width: 30px;
  height: 4px;
  position: absolute;
  bottom: 0;
  left: 0;
}

.is-style-title-h3 {
  border-bottom: 3px solid var(--wp--preset--color--border-color);
  font-size: 22px;
  padding-bottom: 10px;
  margin-bottom: 30px;
  position: relative;
}

.is-style-title-h3::before {
  content: "";
  background: var(--wp--preset--color--primary);
  width: 50px;
  height: 3px;
  position: absolute;
  left: 0;
  bottom: -3px;
}

.is-style-title-h4 {
  font-size: 20px;
  padding-left: 25px;
  margin-bottom: 15px;
  position: relative;
}

.is-style-title-h4::before {
  content: "";
  background: var(--wp--preset--color--primary);
  width: 8px;
  height: 60%;
  position: absolute;
  left: 0;
  top: 7.5px;
}

/* 短罫線スタイル */
.is-style-short-border-line {
  font-weight: normal;
  border-bottom: 2px solid #000;
  font-size: 15px;
  width: fit-content;
  margin-bottom: 30px;
}

/* 経歴スタイル（カラム） */
.is-style-career {
  align-items: stretch;
}


.is-style-career .wp-block-list,
.is-style-career .wp-block-group,
.entry-content .wp-block-group.is-nowrap p,
.entry-content .is-style-career p+p {
  margin-block-start: 0;
}

.is-style-career .wp-block-group+.wp-block-group {
  margin-block-start: 0.5rem;
}

.is-style-career .wp-block-column {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--wp--preset--color--border-color);
  padding: var(--wp--preset--spacing--30);
}

.is-style-career .wp-block-heading {
  border-bottom: 1px solid #333;
  font-weight: bold;
  font-size: 18px;
  padding-bottom: 10px;
  margin-bottom: 20px;
}

.is-style-career .wp-block-list li:first-child {
  margin-top: 0;
}

/* スタッフリストスタイル（カラム） */
.is-style-staff-list {
  gap: 50px 25px !important;
}

.is-style-staff-list .wp-block-column {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.is-style-staff-list .wp-block-image {
  margin-bottom: 20px;
  aspect-ratio: 800 / 590;
  width: 100%;
}

.is-style-staff-list .wp-block-image img {
  aspect-ratio: 800 / 590;
  object-fit: contain;
  width: 100%;
  height: 100%;
}

.is-style-staff-list p {
  line-height: 1;
  margin: 0;
}

.entry-content .is-style-staff-list p+p {
  margin-block-start: 0;
}

/* 役職 */
.is-style-staff-list p:nth-of-type(1) {
  font-size: 12px;
  margin-bottom: 12px;
}

/* 日本語名 */
.is-style-staff-list p:nth-of-type(2) {
  font-size: 15px;
  margin-bottom: 10px;
}

/* 英語名 */
.is-style-staff-list p:nth-of-type(3) {
  font-size: 11px;
  letter-spacing: 0;
}

@media (max-width: 800px) {
  .is-style-staff-list {
    gap: 30px 15px !important;
  }
}

.is-style-title-pattern-01 {
  font-size: 30px;
  position: relative;
  text-align: center;
  margin-bottom: 50px;
}

.is-style-title-pattern-01::after {
  content: "";
  display: block;
  background: var(--wp--preset--color--primary);
  width: 50px;
  height: 4px;
  margin: 20px auto 50px;
}

.is-style-title-pattern-02 {
  font-size: 22px;
  background-color: var(--wp--preset--color--primary);
  color: #fff;
  padding: 5px 15px;
  margin-bottom: 30px;
}

.is-style-title-pattern-03 {
  border-bottom: 2px solid var(--wp--preset--color--primary);
  font-size: 20px;
  padding-bottom: 2px;
  margin-bottom: 15px;
  width: fit-content;
}

.is-style-underline-title {
  border-bottom: 1px solid var(--wp--preset--color--border-color);
  font-size: 18px;
  padding-bottom: 10px;
  margin-bottom: 20px;
}

/* インフォアイコン */
.is-style-before-title-icon-help,
.is-style-before-title-icon-info {
  display: flex;
  align-items: center;
}

.is-style-before-title-icon-help::before,
.is-style-before-title-icon-info::before {
  content: "";
  position: relative;
  mask-size: cover;
  mask-repeat: no-repeat;
  mask-position: center;
  background-color: currentColor;
  display: inline-block;
  width: 25px;
  height: 25px;
  margin-right: 15px;
  flex-shrink: 0;
}

.is-style-before-title-icon-info::before {
  background-color: currentColor;
  mask-image: url('../../images/share/icon_alert.svg');
}

.is-style-before-title-icon-help::before {
  background-color: currentColor;
  mask-image: url('../../images/share/icon_help.svg');
}

@media (max-width: 800px) {
  .is-style-title-h2 {
    font-size: 25px;
    padding-bottom: 20px;
    margin-bottom: 30px;
  }

  .is-style-title-h3 {
    font-size: 20px;
    margin-bottom: 20px;
  }

  .is-style-title-h4 {
    font-size: 18px;
    padding-left: 20px;
  }

  .is-style-title-pattern-01 {
    font-size: 25px;
  }

  .is-style-title-pattern-02 {
    font-size: 20px;
    margin-bottom: 20px;
  }

  .is-style-title-pattern-03 {
    font-size: 18px;
  }

  .is-style-before-title-icon-help::before,
  .is-style-before-title-icon-info::before {
    top: calc((1lh - 25px) / 2);
    margin-right: 10px;
  }
}

/* チェックリスト */
.is-style-checklist li {
  padding-left: 25px;
}

.is-style-checklist li::before {
  content: "";
  width: 15px;
  height: 9px;
  border-left: 3px solid var(--wp--preset--color--primary);
  border-bottom: 3px solid var(--wp--preset--color--primary);
  transform: rotate(-45deg);
  position: absolute;
  top: 8px;
  left: 0;
}

/* カラム分割リスト */
[class*="is-style-col"]>ol,
[class*="is-style-col"]>ul {
  display: grid;
  gap: 10px 30px;
}

.is-style-col2>ol,
.is-style-col2>ul {
  grid-template-columns: repeat(2, 1fr);
}

.is-style-col3>ol,
.is-style-col3>ul {
  grid-template-columns: repeat(3, 1fr);
}

/* col系スタイルのリストアイテムの余白リセット */
[class*="is-style-col"]>ol>li,
[class*="is-style-col"]>ul>li {
  margin-top: 0;
}

[class*="is-style-col"]>ol.wp-block-list>li+li,
[class*="is-style-col"]>ul.wp-block-list>li+li {
  margin-block-start: 0;
}

@media (max-width: 800px) {

  [class*="is-style-col"]>ol,
  [class*="is-style-col"]>ul {
    grid-template-columns: repeat(1, 1fr);
    gap: 5px;
  }
}

/* カード型レイアウト */
.is-style-card-flow .wp-block-column,
.is-style-card .wp-block-column {
  display: flex;
  flex-direction: column;
}

.is-style-card-flow .wp-block-column .wp-block-buttons,
.is-style-card .wp-block-column .wp-block-buttons {
  margin-block-start: var(--wp--style--block-gap);
  margin-top: auto;
}

.is-style-card-flow .wp-block-column .wp-block-buttons .wp-block-button,
.is-style-card .wp-block-column .wp-block-buttons .wp-block-button {
  margin-inline: auto;
}

/* カードフロー */
.is-layout-flex.is-style-card-flow {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 3%;
}

.is-style-card-flow .wp-block-column {
  width: auto;
}

.is-style-card-flow .wp-block-column+.wp-block-column {
  position: relative;
}

/* カードフロー矢印（カラム間・ブロック間共通） */
.is-style-card-flow .wp-block-column+.wp-block-column:not(:empty)::before,
.is-style-card-flow+.is-style-card-flow .wp-block-column:first-child:not(:empty)::before {
  content: "";
  border-style: solid;
  border-width: 12px 0 12px 12px;
  border-color: transparent transparent transparent #333;
  position: absolute;
  left: calc(-3% / 2 - 6px);
  top: calc(50% + -6px);
}

@media (min-width: 801px) {
  .is-style-card-flow+.is-style-card-flow .wp-block-column:first-child:not(:empty)::before {
    left: calc(-3% / 2 - 6px) !important;
  }
}

/* カードフローが連続した場合、2つ目の最初のカラムの前にも矢印を表示 */
.is-style-card-flow+.is-style-card-flow {
  position: relative;
  margin-block-start: 3rem;
}

/* PC表示（801px以上）でのカラム数に応じた矢印位置調整 */
@media (min-width: 801px) {

  /* 2カラムの場合の矢印位置調整 */
  .is-style-card-flow:has(.wp-block-column:nth-child(2):last-child) .wp-block-column+.wp-block-column:not(:empty)::before {
    left: -4%;
  }

  /* 3カラムの場合の矢印位置調整 */
  .is-style-card-flow:has(.wp-block-column:nth-child(3):last-child) .wp-block-column+.wp-block-column:not(:empty)::before {
    left: -6%;
  }

  /* 4カラムの場合の矢印位置調整 */
  .is-style-card-flow:has(.wp-block-column:nth-child(4):last-child) .wp-block-column+.wp-block-column:not(:empty)::before {
    left: -8%;
  }

  /* 連続したカードフロー：2カラムの場合の矢印位置調整 */
  .is-style-card-flow+.is-style-card-flow:has(.wp-block-column:nth-child(2):last-child) .wp-block-column:first-child:not(:empty)::before {
    left: -4%;
  }

  /* 連続したカードフロー：3カラムの場合の矢印位置調整 */
  .is-style-card-flow+.is-style-card-flow:has(.wp-block-column:nth-child(3):last-child) .wp-block-column:first-child:not(:empty)::before {
    left: -6%;
  }

  /* 連続したカードフロー：4カラムの場合の矢印位置調整 */
  .is-style-card-flow+.is-style-card-flow:has(.wp-block-column:nth-child(4):last-child) .wp-block-column:first-child:not(:empty)::before {
    left: -8%;
  }
}

@media (max-width: 800px) {

  /* カード型レイアウト：スマホでは縦並び */
  .is-style-card {
    flex-wrap: wrap;
  }

  /* スマホでは縦並び（gridを無効化） */
  .is-layout-flex.is-style-card-flow {
    display: flex;
    flex-direction: column;
    gap: 3rem;
  }

  .is-style-card-flow .wp-block-column+.wp-block-column:not(:empty)::before {
    left: calc(50% - 6px);
    /* カード間のギャップ（gap: 3rem）の中央に矢印の中心を配置 */
    /* ギャップの中央: -1.5rem（3rem / 2） */
    /* 矢印要素の上端から矢印の視覚的な中心まで: 12px */
    /* 矢印の中心を-1.5remの位置に配置するため、要素の上端は -1.5rem - 12px */
    top: calc(-1.5rem - 12px);
    transform: translateX(0) rotate(90deg);
  }

  /* カードフローが連続した場合、矢印のスペースを確保 */
  .is-style-card-flow+.is-style-card-flow {
    margin-block-start: 3rem;
  }

  /* カードフローが連続した場合の矢印もスマホでは縦向きに */
  .is-style-card-flow+.is-style-card-flow .wp-block-column:first-child:not(:empty)::before {
    left: calc(50% - 6px);
    top: calc(-1.5rem - 12px);
    transform: translateX(0) rotate(90deg);
  }
}

/* FAQ */
.wp-block-details.is-style-faq summary {
  font-family: var(--font_jp);
  position: relative;
}

.wp-block-details.is-style-faq summary::before {
  content: "Q";
  color: var(--wp--preset--color--base-black);
  font-size: 23px;
  margin-right: 20px;
}

.wp-block-details.is-style-faq .js-accordion-content {
  margin-block-start: 0.5rem;
  padding-left: 35px;
}


/* アコーディオン */
.wp-block-details .js-accordion-content {
  overflow: hidden;
}

:not(.editor-styles-wrapper) .wp-block-details summary::marker {
  content: none;
}

.wp-block-details .faq-open-ico {
  display: inline-block;
  width: 40px;
  height: 40px;
  position: absolute;
  right: 30px;
  top: 50%;
  transform: translateY(-50%);
}

.wp-block-details .faq-open-ico::before,
.wp-block-details .faq-open-ico::after {
  content: "";
  display: block;
  background: #333;
  position: absolute;
  top: 50%;
  left: 50%;
}

.wp-block-details .faq-open-ico::before {
  width: 16px;
  height: 2px;
  transform: translateX(-50%);
}

.wp-block-details .faq-open-ico::after {
  width: 16px;
  height: 2px;
  transform: rotate(90deg) translateX(-50%);
  transform-origin: left;
  transition: transform 0.5s;
}

.wp-block-details .is-open .faq-open-ico::after {
  transform: rotate(0) translateX(-50%);
}


@media (max-width: 800px) {
  .wp-block-details .faq-open-ico {
    right: 0;
  }
}

.wp-block-accordion-heading__toggle:hover .wp-block-accordion-heading__toggle-title {
  text-decoration: none;
}

@media (any-hover:hover) {
  .wp-block-accordion-heading__toggle:hover .wp-block-accordion-heading__toggle-title {
    text-decoration: underline;
  }

}

/* 流れの矢印 */
.is-style-hr-arrow-line {
  margin: 25px auto 30px;
  padding: 0;
  border: 0;
  width: 100% !important;
  border-top: solid 1.5px var(--wp--preset--color--border-color);
  text-align: center;
  position: relative;
  overflow: visible;
}

.is-style-hr-arrow-line::after {
  content: "";
  background-color: #FFF;
  width: 60px;
  height: 50px;
  display: block;
  position: absolute;
  z-index: 1;
  left: calc(50% - 30px);
  top: -1.5rem;
}

.is-style-hr-arrow-line::before {
  content: "";
  background-color: var(--wp--preset--color--border-color);
  mask-image: url('../../images/share/arrow-down.svg');
  mask-size: 35px 35px;
  mask-repeat: no-repeat;
  mask-position: center center;
  width: 60px;
  height: 50px;
  display: block;
  position: absolute;
  z-index: 2;
  left: calc(50% - 30px);
  top: -1.5rem;
}

/* 下向き区切り */
.is-style-down-separator {
  margin: 25px auto 30px;
  padding: 0;
  border: 0;
  width: 100% !important;
  border-top: solid 2px var(--wp--preset--color--border-color);
  position: relative;
  overflow: visible;
}

.is-style-down-separator::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -14px;
  width: 20px;
  height: 20px;
  border-bottom: 2px solid var(--wp--preset--color--border-color);
  border-right: 2px solid var(--wp--preset--color--border-color);
  transform: translate(-50%, -50%) rotate(45deg);
  z-index: 3;
}

.is-style-down-separator::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  background: #fff;
  width: 70px;
  height: 20px;
  transform: translate(-50%, -50%);
  z-index: 2;
}

/* ボタンブロック カスタムスタイル */
/* 電話番号ボタン */
.wp-block-button.is-style-telephone .wp-block-button__link::before {
  content: "";
  display: inline-block;
  width: 13px;
  height: 16px;
  margin-right: 8px;
  background-color: currentColor;
  mask-image: url('../../images/share/icon_tel.svg');
  mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  vertical-align: middle;
}

/* お問い合わせボタン */
.wp-block-button.is-style-contact .wp-block-button__link::before {
  content: "";
  display: inline-block;
  width: 17px;
  height: 13px;
  margin-right: 8px;
  background-color: currentColor;
  mask-image: url('../../images/share/icon_mail.svg');
  mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  vertical-align: middle;
}

/* Web予約ボタン */
.wp-block-button.is-style-web-reservation .wp-block-button__link::before {
  content: "";
  display: inline-block;
  width: 18px;
  height: 18px;
  margin-right: 8px;
  background-color: currentColor;
  mask-image: url('../../images/share/icon_calendar.svg');
  mask-size: 18px 18px;
  mask-repeat: no-repeat;
  mask-position: center;
  vertical-align: middle;
}

/* アクセスボタン */
.wp-block-button.is-style-access .wp-block-button__link::before {
  content: "";
  display: inline-block;
  width: 12px;
  height: 16px;
  margin-right: 8px;
  background-color: currentColor;
  mask-image: url('../../images/share/icon_access.svg');
  mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  vertical-align: middle;
}

/* LINEで予約ボタン */
.wp-block-button.is-style-line-reservation .wp-block-button__link {
  padding: 12px 30px 12px 20px;
  background-color: #4CC764;
  color: #fff;
  transition: filter 0.3s, box-shadow 0.3s;
}

.wp-block-button.is-style-line-reservation .wp-block-button__link:focus-visible {
  background-color: #4CC764 !important;
  /* 汎用スタイルを打ち消す */
  filter: brightness(0.95);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

@media (any-hover:hover) {
  .wp-block-button.is-style-line-reservation .wp-block-button__link:hover {
    background-color: #4CC764 !important;
    /* 汎用スタイルを打ち消す */
    filter: brightness(0.95);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  }
}

.wp-block-button.is-style-line-reservation .wp-block-button__link::before {
  content: "";
  display: inline-block;
  width: 30px;
  height: 30px;
  margin-right: 8px;
  background-image: url('../../images/share/icon_line.svg');
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  vertical-align: middle;
}

/* 電話CTA */
.entry-content .is-style-tel-layout {
  background: #f5f5f5;
  padding: 5%;
  margin: 0 auto;
}

/* .is-style-tel-layout {
  max-width: 800px;
} */


.is-style-tel-layout .wp-block-group+.wp-block-group {
  margin-block-start: 0;
}

.is-style-tel-layout .l-ttl {
  display: table;
  border-bottom: 1px solid var(--wp--preset--color--base-black);
  font-weight: bold;
  font-size: 18px;
  line-height: 1.7;
  padding: 0 0 15px;
  margin: 0 auto 25px;
}

/* 電話アイコンのサイズ */
.is-style-tel-layout .tel-icon img {
  width: 25px;
  height: 31px;
}

/* 電話番号スタイル（お問い合わせ用・大）※パターンファイル用に残す */
.is-style-tel-number {
  font-size: 35px;
  font-weight: bold;
  line-height: 1.2;
  text-align: center;
  margin: 20px 0;
}

.is-style-tel-number a {
  color: inherit;
  text-decoration: none;
}

/* 電話番号スタイル（シンプル版） */
.is-style-single-tel-number {
  font-size: 25px;
  font-family: var(--font_en);
  font-weight: 500;
}

.is-style-single-tel-number a {
  color: inherit;
  text-decoration: none;
}

/* 数字装飾 */
.is-style-num-decoration {
  display: block;
  font-weight: bold;
  font-size: 13px;
  line-height: 1;
  margin-bottom: 5px;
  font-family: var(--font_en);
  color: var(--wp--preset--color--primary);
}

/* 数字装飾（白抜き） */
.is-style-num-decoration-outlined {
  background: var(--wp--preset--color--primary);
  color: #fff;
  border-radius: 50px;
  font-family: var(--font_en);
  display: table;
  font-weight: bold;
  font-size: 11px;
  line-height: 25px;
  padding: 0 20px;
  margin: 0 auto 10px;
}

/* ラベル（枠付き） */
.is-style-label-bordered {
  width: 75px;
  flex-shrink: 0;
  border: 1px solid #000;
  text-align: center;
  font-weight: bold;
  padding: 2px 0;
  font-size: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* リボンラベル */
.is-style-ribbon-label {
  display: inline-block;
  background-color: var(--wp--preset--color--primary);
  color: var(--wp--preset--color--primary-text);
  font-size: 12px;
  line-height: 25px;
  padding: 0 9px;
  margin-right: 20px;
  position: relative;
}

.is-style-ribbon-label::after {
  content: "";
  border-style: solid;
  border-width: 12.5px 0 12.5px 7px;
  border-color: transparent transparent transparent var(--wp--preset--color--primary);
  position: absolute;
  top: 0;
  right: -6.5px;
}

/* サブタイトル */
.is-style-sub-title {
  display: flex;
  align-items: center;
  font-family: var(--font_jp);
  font-size: 18px;
  margin-bottom: 20px;
}

.is-style-sub-title::before {
  content: "";
  background: var(--wp--preset--color--primary);
  width: 30px;
  height: 2px;
  margin-right: 25px;
}

/* 受付時間・休診日を揃える */
.is-style-tel-layout .time-info-wrapper {
  display: grid;
  grid-template-columns: auto auto;
  gap: var(--wp--preset--spacing--10);
  justify-content: center;
  align-items: center;
}

.is-style-tel-layout .time-info-wrapper>.wp-block-group {
  display: contents;
}


@media (max-width: 800px) {
  .is-style-tel-layout {
    padding: 30px 20px;
  }

  .is-style-tel-layout .l-ttl {
    display: block;
    text-align: center;
    font-size: 15px;
  }

  /* 電話アイコンのスマホサイズ調整 */
  .is-style-tel-layout .tel-icon img {
    width: 20px;
    height: 25px;
  }

  .is-style-tel-number {
    font-size: 25px;
  }

  .is-style-single-tel-number {
    font-size: 20px;
  }

  .is-style-label-bordered {
    font-size: 10px;
    padding: 6px 15px;
  }
}


/* before-afterスライダー */
.is-style-before-after .wp-block-delta-slider-blocks-slider-item p {
  background: #fff;
  font-size: 11px;
  font-weight: bold;
  line-height: 1.5;
  text-align: left;
  padding: 3px 5px;
  position: absolute;
  bottom: 10px;
  left: 10px;
  margin: 0;
}

.is-style-before-after .splide__pagination {
  position: absolute;
  bottom: 1em;
  left: 0;
  right: 0;
  z-index: 1;
}

/* テキスト付きスライダー */
.is-style-text-slider.wp-block-delta-slider-blocks-slider .splide__arrow {
  top: 255px;
  transform: none;
}

@media (max-width: 1024px) {
  .is-style-text-slider.wp-block-delta-slider-blocks-slider .splide__arrow {
  top: clamp(58.8px, 25.87vw - 49.84px, 215.04px);
}
}
