@charset "UTF-8";
.wp-block-acf-treatment-links {
  container-type: inline-size;
  --cols: 2;
  --gap: clamp(12px, 1.5vw, 20px);
  --speed: 0.3s;
  --item-color: var(--wp--preset--color--primary);
  --item-color-700: var(--wp--preset--color--primary-700);
}
.wp-block-acf-treatment-links .items-wrapper {
  display: flex;
  flex-direction: column;
  row-gap: clamp(28px, 3vw, 40px);
}
.wp-block-acf-treatment-links .group-title {
  position: relative;
  margin-bottom: clamp(14px, 1.6vw, 20px);
  padding-left: 14px;
  font-size: clamp(1.05rem, 1.3vw, 1.2rem);
  font-weight: 500;
  letter-spacing: 0.04em;
  border-left: 3px solid var(--item-color);
}
.wp-block-acf-treatment-links .items {
  --item-min-width: 200px;
  width: 100%;
  margin: 0;
  padding: 0;
  list-style: none;
  /*
  flexのgrow基準だと最終行の余りが伸びてカードごとに幅がバラつくため、
  gridのauto-fillで列幅を揃える（列に満たない最終行も同じ幅を維持できる）
  */
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(var(--item-min-width), 1fr));
  justify-content: center;
  gap: var(--gap);
}
@media screen and (min-width: 1000px) {
  .wp-block-acf-treatment-links .items {
    --item-min-width: 250px;
  }
}
.wp-block-acf-treatment-links .item {
  max-width: 100%;
}
.wp-block-acf-treatment-links .item .inner {
  height: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  column-gap: 8px;
  padding-left: clamp(8px, 1vw, 12px);
  padding-right: clamp(8px, 1vw, 12px);
  text-decoration: none;
  color: inherit;
  border-radius: var(--wp--custom--border-radius);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  background-image: linear-gradient(to bottom, transparent 50%, rgba(20, 20, 20, 0.1));
  background-color: var(--item-color);
  transition: background-color 0.2s linear, box-shadow 0.2s linear;
}
.wp-block-acf-treatment-links .item .inner::after {
  content: "";
  flex-shrink: 0;
  display: flex;
  align-items: center;
  width: 7px;
  aspect-ratio: 1/1;
  border-style: solid;
  border-color: var(--wp--preset--color--base-bg);
  border-width: 2px 2px 0 0;
  transform: translateX(0rem) rotate(45deg);
  transition: border-color 0.2s linear, transform 0.2s ease-in-out;
}
.wp-block-acf-treatment-links .item .inner {
  /*
  リンクであることを伝える最小限の変化（背景色を少し濃く＋アウトライン）に留める。
  浮き上がり＋影の拡大は全カード一律だと「生成AIっぽい」定番ホバーになるため避ける
  （.agents/wp-block-for-ai/references/anti-patterns.md参照）
  */
}
.wp-block-acf-treatment-links .item .inner:hover, .wp-block-acf-treatment-links .item .inner:focus-visible {
  background-color: color-mix(in srgb, var(--item-color) 85%, #000);
  box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--item-color-700) 60%, transparent);
}
.wp-block-acf-treatment-links .item .inner:hover::after, .wp-block-acf-treatment-links .item .inner:focus-visible::after {
  transform: translateX(0.2rem) rotate(45deg);
}
.wp-block-acf-treatment-links .item .inner:has(.image):hover .image img {
  transform: scale(1.03);
}
.wp-block-acf-treatment-links .item .image {
  position: absolute;
  top: 0;
  left: 0;
  overflow: hidden;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: inherit;
  z-index: 1;
}
.wp-block-acf-treatment-links .item .image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--speed) ease-in-out;
}
.wp-block-acf-treatment-links .item .label {
  position: relative;
  z-index: 1;
  flex-grow: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  line-height: 1.3;
  padding: clamp(8px, 0.8vw, 11px) clamp(10px, 1.4vw, 16px);
  border-radius: var(--wp--custom--border-radius);
  font-size: clamp(0.95rem, 1.2vw, 1.05rem);
  font-weight: bold;
}
.wp-block-acf-treatment-links .item:has(.image) .inner {
  aspect-ratio: 4/3;
  background-color: transparent;
  border-radius: calc(var(--wp--custom--border-radius) * 1.5);
}
.wp-block-acf-treatment-links .item:has(.image) .inner::after {
  display: none;
}
.wp-block-acf-treatment-links .item:has(.image) .label {
  color: inherit;
  backdrop-filter: blur(4px);
  background-color: rgba(255, 255, 255, 0.7);
}
.wp-block-acf-treatment-links.acf-block-preview > * {
  pointer-events: none;
}
.wp-block-acf-treatment-links.acf-block-preview .items-wrapper:not(:has(.item)) {
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #999;
  background-color: rgba(0, 0, 0, 0.03);
  border: 2px dashed #ccc;
  border-radius: var(--wp--custom--border-radius);
}
.wp-block-acf-treatment-links.acf-block-preview .items-wrapper:not(:has(.item))::before {
  content: "ブロックの編集で項目を追加して下さい";
}
.wp-block-acf-treatment-links {
  /*
  診療科カラー切り替え（内科=primary系グリーン／眼科=secondary系ブルー）
  `.department-eye` クラスの有無で --item-color をカスタムプロパティごと切り替える。
  doctor-cardブロックと同じ命名パターンを踏襲。
  */
}
.wp-block-acf-treatment-links.department-eye {
  --item-color: var(--wp--preset--color--secondary);
  --item-color-700: var(--wp--preset--color--secondary-700);
}
.wp-block-acf-treatment-links {
  /*
  コンパクト（記事下部の「関連ページ」等、小さめのボタン表示にしたい場合）
  */
}
.wp-block-acf-treatment-links.is-style-compact .items {
  justify-content: flex-start;
  gap: 14px 20px;
}
.wp-block-acf-treatment-links.is-style-compact .item {
  --item-min-width: auto;
  max-width: none;
}
.wp-block-acf-treatment-links.is-style-compact .item .inner {
  aspect-ratio: auto;
  padding: 0.8em 1.4em;
  background-color: transparent;
  background-image: none;
  box-shadow: none;
  border: 1px solid var(--item-color);
  border-radius: var(--wp--custom--border-radius);
  transition: background-color 0.2s linear;
}
.wp-block-acf-treatment-links.is-style-compact .item .inner::after {
  border-color: var(--item-color);
  width: 6px;
  transition: border-color 0.2s linear, transform 0.2s ease-in-out;
}
.wp-block-acf-treatment-links.is-style-compact .item .inner:hover, .wp-block-acf-treatment-links.is-style-compact .item .inner:focus-visible {
  background-color: var(--item-color);
}
.wp-block-acf-treatment-links.is-style-compact .item .inner:hover::after, .wp-block-acf-treatment-links.is-style-compact .item .inner:focus-visible::after {
  border-color: #fff;
}
.wp-block-acf-treatment-links.is-style-compact .item .inner:hover .label, .wp-block-acf-treatment-links.is-style-compact .item .inner:focus-visible .label {
  color: #fff;
}
.wp-block-acf-treatment-links.is-style-compact .item .inner:focus-visible {
  outline: 2px solid var(--item-color);
  outline-offset: 3px;
}
.wp-block-acf-treatment-links.is-style-compact .item .label {
  color: var(--item-color-700);
  background: none;
  padding: 0;
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  transition: color 0.2s linear;
}

/*# sourceMappingURL=style.css.map */
