/**
 * File: top/action.css
 * Usage: TOPページ ACTION セクション
 */

.ly_action {
  position: relative;
  padding-block: 96px;
  background: var(--color-accent);
  color: var(--color-white);
}

.ly_action::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(rgba(168, 141, 106, 0.86), rgba(168, 141, 106, 0.86)),
    linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)),
    url(../../img/top/action-bg.jpg) center / cover no-repeat;
  pointer-events: none;
}

.bl_action {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 48px;
}

.bl_actionHead {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 24px;
}

.bl_actionHead_btn {
  flex-shrink: 0;
}

/* Swiper:画面幅いっぱい(1080pxで切らない)。先頭オフセットは JS で制御 */
.bl_actionSwiper {
  width: 100vw;
  margin-inline: calc(50% - 50vw);
}

/* カード */
.bl_actionSlide {
  width: min(86vw, 391px);
  height: auto;
}

.bl_actionCard {
  display: block;
  height: 100%;
  padding: 8px;
  border-radius: 16px;
  background: var(--color-white);
  color: var(--color-black);
}

.bl_actionCard_img {
  display: block;
  aspect-ratio: 375 / 200;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 0 4px rgba(28, 28, 28, 0.08);
}

.bl_actionCard_img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  transition: transform 0.5s ease;
}

.bl_actionCard:hover .bl_actionCard_img img {
  transform: scale(1.04);
}

.bl_actionCard_body {
  display: block;
  padding: 16px 24px 24px;
}

.bl_actionCard_tag {
  display: inline-block;
  padding: 8px 16px;
  background: var(--color-accent);
  color: var(--color-white);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.1em;
}

.bl_actionCard_name {
  display: block;
  margin-top: 8px;
  font-size: 16px;
  line-height: 1.75;
  letter-spacing: 0.05em;
}

@media screen and (min-width: 768px) {
  .ly_action {
    padding-block: 160px;
  }

  .bl_action {
    gap: 64px;
  }

  .bl_actionHead {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-end;
  }

  .bl_actionSlide {
    width: 391px;
  }
}

/* ============================================================
 支援カードの複数リンク用モーダル
 (複数リンクのカードは <button> で描画。リンク一覧をモーダル表示)
============================================================ */
button.bl_actionCard {
  width: 100%;
  margin: 0;
  border: 0;
  font: inherit;
  color: var(--color-black);
  text-align: inherit;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
}

.bl_actionModal[hidden] {
  display: none;
}

.bl_actionModal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--pad-inner);
}

.bl_actionModal_overlay {
  position: absolute;
  inset: 0;
  background: rgba(28, 28, 28, 0.6);
  cursor: pointer;
}

.bl_actionModal_panel {
  position: relative;
  z-index: 1;
  width: min(100%, 480px);
  max-height: 80vh;
  overflow-y: auto;
  padding: 40px 24px 32px;
  border-radius: 16px;
  background: var(--color-white);
  box-shadow: 0 8px 32px rgba(28, 28, 28, 0.18);
}

.bl_actionModal_close {
  position: absolute;
  top: 12px;
  right: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  color: var(--color-dgray);
  background: none;
  border: 0;
  cursor: pointer;
}

.bl_actionModal_close svg {
  width: 20px;
  height: 20px;
}

.bl_actionModal_ttl {
  margin-bottom: 24px;
  padding-right: 32px;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: 0.05em;
  color: var(--color-black);
}

.bl_actionModal_list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.bl_actionModal_link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 20px;
  border: 1px solid var(--color-accent);
  border-radius: 8px;
  color: var(--color-black);
  font-size: 16px;
  line-height: 1.6;
  letter-spacing: 0.05em;
  transition: background 0.3s ease, color 0.3s ease;
}

.bl_actionModal_link::after {
  content: '';
  flex: 0 0 auto;
  width: 8px;
  height: 8px;
  border-top: 1.5px solid currentColor;
  border-right: 1.5px solid currentColor;
  transform: rotate(45deg);
}

.bl_actionModal_link:hover {
  background: var(--color-accent);
  color: var(--color-white);
}

@media screen and (min-width: 768px) {
  .bl_actionModal_panel {
    padding: 48px 32px 40px;
  }
}
