.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.25);
  z-index: 10000;
  box-sizing: border-box;
  padding: 20px;
  overflow-y: auto; /* オーバーレイでスクロール */
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal-overlay.is-active {
  opacity: 1;
}

.modal {
  position: relative;
  background-color: #fff;
  border-radius: 8px;
  padding: 40px;
  max-width: 680px;
  width: 100%;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  margin: auto; /* 中央配置（縦横） */
  transform: scale(0.9);
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.modal-overlay.is-active .modal {
  transform: scale(1);
  opacity: 1;
}

.modal__close {
  position: absolute;
  top: 15px;
  right: 15px;
  width: 30px;
  height: 30px;
  background: none;
  border: 2px solid #999;
  border-radius: 50%;
  cursor: pointer;
  font-size: 18px;
  color: #999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.modal__close:hover {
  border-color: #333;
  color: #333;
}

.modal__title {
  font-size: 20px;
  font-weight: bold;
  text-align: center;
  margin-bottom: 24px;
  color: #333;
}

.modal__content {
  font-size: 14px;
  line-height: 1.8;
  color: #333;
  margin-bottom: 20px;
}

/* スクロールエリア（免責事項など） */
/* 免責事項エリア */
.modal__disclaimer {
  max-height: 220px;
  overflow-y: auto;
  padding: 20px;
  background-color: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 6px;
  margin-top: 20px;
  font-size: 13px;
  line-height: 1.8;
  color: #495057;
}

.modal__disclaimer::-webkit-scrollbar {
  width: 8px;
}

.modal__disclaimer::-webkit-scrollbar-track {
  background: #e9ecef;
  border-radius: 4px;
}

.modal__disclaimer::-webkit-scrollbar-thumb {
  background: #adb5bd;
  border-radius: 4px;
}

.modal__disclaimer::-webkit-scrollbar-thumb:hover {
  background: #868e96;
}

/* タイトル */
.modal__disclaimer-title {
  font-size: 15px;
  font-weight: bold;
  color: #212529;
  margin-bottom: 20px;
  padding-bottom: 8px;
  border-bottom: 1px solid #dee2e6;
  text-align: center;
}

/* 番号付きリスト */
.modal__disclaimer-list {
  margin: 0;
  counter-reset: item;
  list-style: none;
}

.modal__disclaimer-list > .modal__disclaimer-item {
  counter-increment: item;
  margin-bottom: 15px;
  position: relative;
}
.modal__disclaimer-list > .modal__disclaimer-item:last-child {
  margin-bottom: 0;
}

.modal__disclaimer-list > .modal__disclaimer-item strong::before {
  content: counter(item) ".";
  margin-right: 4px;
}

/* 各項目のタイトル */
.modal__disclaimer-item-title {
  font-weight: bold;
  color: #343a40;
  margin-bottom: 8px;
  font-size: 13px;
}

.modal__disclaimer-item-title strong {
  color: #495057;
}

/* 詳細リスト */
.modal__disclaimer-item-details {
  margin: 8px 0 0 0;
  padding-left: 20px;
  list-style: disc;
}

.modal__disclaimer-item-details li {
  margin-bottom: 5px;
  color: #6c757d;
  line-height: 1.7;
  font-size: 12px;
}

/* 確認文 */
.modal__disclaimer-note {
  margin-top: 20px;
  font-size: 13px;
  color: #495057;
  text-align: center;
}

.modal__disclaimer-note strong {
  color: #dc3545;
  font-weight: bold;
}

@media (max-width: 768px) {
  .modal__disclaimer {
    max-height: 250px;
    padding: 16px;
    font-size: 12px;
  }

  .modal__disclaimer-title {
    font-size: 14px;
  }

  .modal__disclaimer-item-details {
    padding-left: 18px;
  }
}

.modal__disclaimer::-webkit-scrollbar {
  width: 8px;
}

.modal__disclaimer::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 4px;
}

.modal__disclaimer::-webkit-scrollbar-thumb {
  background: #bbb;
  border-radius: 4px;
}

.modal__disclaimer::-webkit-scrollbar-thumb:hover {
  background: #999;
}

.modal__disclaimer > li {
  margin-bottom: 10px;
}

.modal__disclaimer > li > p {
  margin-bottom: 6px;
}

.modal__disclaimer strong {
  color: #d32f2f;
}

.modal__buttons {
  margin-top: 20px;
  padding-top: 20px;
  border-top: 1px solid #dee2e6;
  display: flex;
  gap: 16px;
  justify-content: center;
}

.modal__button {
  padding: 12px 32px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  font-weight: bold;
  transition: opacity 0.2s;
  min-width: 160px;
}

.modal__button:hover {
  opacity: 0.85;
}

.modal__button--close {
  background-color: #6c757d;
  color: #fff;
}

.modal__button--proceed {
  background-color: #ffa524;
  color: #fff;
}

@media (max-width: 768px) {
  .modal {
    padding: 30px 20px;
  }
  
  .modal__button {
    min-width: 120px;
    padding: 10px 20px;
  }
  
  .modal__disclaimer {
    max-height: 200px;
  }
}

.modal__content .btn_area {
  width: 350px;
  margin: 20px auto;
}
.modal__content .btn_area a {
  display: block;
  line-height: 50px;
  background: #2ea35d;
  color: #ffffff;
  font-weight: bold;
  text-align: center;
}


/* 強調リンク（オレンジ） */
.modal__highlight-link a {
  color: #ff8004;
  font-weight: bold;
  text-decoration: underline;
}

.modal__highlight-link a:hover {
  opacity: .8;
}

/* ダウンロード案内ボックス（オプション） */
.modal__download-notice {
  background-color: #fff8f0;
  border-left: 4px solid #ff8004;
  padding: 12px 16px;
  margin: 16px 0;
  border-radius: 4px;
}