/* ========================================
   クリックトリガー型 汎用モーダル
   ======================================== */

/* オーバーレイ（全画面背景） */
.modal-trigger-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* ラッパー */
.modal-trigger-wrapper {
  position: relative;
  padding-top: 24px;
  max-width: 90%;
  width: auto;
  display: flex;
  flex-direction: column;
}

/* コンテンツ部 */
.modal-trigger-container {
  position: relative;
  background-color: #fff;
  padding: 16px;
  max-height: 70vh;
  overflow-y: auto;
  box-sizing: border-box;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* 閉じるボタン（::before/::after で X を描画） */
.modal-trigger-close-btn {
  position: absolute;
  top: 4px;
  right: -16px;
  background: #1f1f1f;
  border: 0;
  border-radius: 40px;
  cursor: pointer;
  width: 40px;
  height: 40px;
  z-index: 1;
  padding: 0;
  transition: opacity 0.2s;
}

.modal-trigger-close-btn:hover {
  opacity: 0.8;
}

.modal-trigger-close-btn::before,
.modal-trigger-close-btn::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 22px;
  height: 3px;
  background-color: #fff;
  border-radius: 2px;
}

.modal-trigger-close-btn::before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.modal-trigger-close-btn::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

/* コンテンツ内の画像をレスポンシブに */
.modal-trigger-container img {
  max-width: 100%;
  height: auto;
}

/* ========================================
   SP対応
   ======================================== */
@media (max-width: 768px) {
  .modal-trigger-wrapper {
    max-width: 92%;
    width: 100%;
  }

  .modal-trigger-close-btn {
    right: 0;
    top: 0;
    width: 36px;
    height: 36px;
  }

  .modal-trigger-close-btn::before,
  .modal-trigger-close-btn::after {
    width: 18px;
    height: 2px;
  }

  .modal-trigger-container {
    padding: 12px;
    max-height: 75vh;
  }
}


.modal-trigger-container h2 {
  text-align: center;
  border-bottom: 1px solid #ccc;
  font-size: 1.4rem;
  font-weight: bold;
  margin: 0 auto 24px;
  padding: 0 0 6px;
}



/* クーポン説明 */
.coupon-guide {
  font-family: "Meiryo", "Hiragino Kaku Gothic ProN", sans-serif;
  font-size: 14px;
  text-align: left;
  color: #333;
  line-height: 1.7;
  max-width: 730px;
}

.coupon-guide .cg-notice {
  background: #fff8dc;
  border: 1px solid #e6b800;
  padding: 2px 0;
  margin-bottom: 16px;
}

.coupon-guide .cg-notice summary {
  padding: 9px 14px;
  cursor: pointer;
  font-size: 13px;
  font-weight: bold;
  color: #5a3e00;
  list-style: none;
  display: flex;
  justify-content: space-between;
}

.coupon-guide .cg-notice summary::after {
  content: "▼";
}

.coupon-guide .cg-notice[open] summary::after {
  content: "▲";
}

.coupon-guide .cg-notice ul {
  margin: 0;
  padding: 0 14px 12px 28px;
  font-size: 13px;
}

.coupon-guide .cg-notice ul li {
  margin: 4px 0;
}

.coupon-guide .cg-step {
  display: flex;
  gap: 12px;
  margin-bottom: 20px;
  align-items: flex-start;
}

.coupon-guide .cg-num {
  background: #1B3C6E;
  color: #fff;
  font-weight: bold;
  font-size: 13px;
  min-width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 2px;
}

.coupon-guide .cg-content {
  flex: 1;
}

.coupon-guide .cg-content strong {
  color: #1B3C6E;
}

.coupon-guide .cg-content .cg-ss {
  border: 1px dashed #ccc;
  background: #f9f9f9;
  padding: 12px;
  text-align: center;
  color: #aaa;
  font-size: 12px;
  margin-top: 8px;
}

.coupon-guide .cg-content .cg-ss img {
  max-width: 100%;
  display: block;
  margin: 0 auto;
}

.coupon-guide .cg-note {
  background: #f0f7ff;
  border-left: 3px solid #0077cc;
  padding: 7px 11px;
  font-size: 12px;
  margin-top: 8px;
}

.coupon-guide hr {
  border: none;
  border-top: 1px solid #eee;
  margin: 4px 0 16px;
}