/* PDF 添付文書 利用規約モーダル */

.pdf-terms-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease;
}

.pdf-terms-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.pdf-terms-modal {
  position: relative;
  width: 100%;
  max-width: 520px;
  max-height: calc(100vh - 40px);
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: translateY(10px);
  transition: transform 0.2s ease;
}

.pdf-terms-overlay.is-open .pdf-terms-modal {
  transform: translateY(0);
}

.pdf-terms-modal__header {
  position: relative;
  padding: 18px 48px 14px 22px;
  border-bottom: 1px solid #eee;
}

.pdf-terms-modal__title {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: #333;
}

.pdf-terms-modal__close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 32px;
  height: 32px;
  border: none;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  color: #777;
  cursor: pointer;
  border-radius: 50%;
  transition: background-color 0.2s;
}

.pdf-terms-modal__close:hover,
.pdf-terms-modal__close:focus-visible {
  background: #f0f0f0;
  color: #333;
  outline: none;
}

.pdf-terms-modal__body {
  padding: 18px 22px;
  font-size: 14px;
  line-height: 1.7;
  color: #444;
  white-space: pre-wrap;
  overflow-y: auto;
}

.pdf-terms-modal__lead {
  margin: 0 0 14px;
  font-size: 15px;
  font-weight: 700;
  color: #333;
}

.pdf-terms-modal__actions {
  padding: 14px 22px 18px;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  border-top: 1px solid #eee;
  background: #fafafa;
}

.pdf-terms-btn {
  min-width: 130px;
  height: 42px;
  padding: 0 18px;
  border: none;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.2s;
}

.pdf-terms-btn--agree {
  background: var(--brand-pink, #cc5d77);
  color: #fff;
}

.pdf-terms-btn--agree:hover,
.pdf-terms-btn--agree:focus-visible {
  background: var(--brand-pink-dark, #be4f68);
  outline: none;
}

.pdf-terms-btn--cancel {
  background: #e0e0e0;
  color: #333;
}

.pdf-terms-btn--cancel:hover,
.pdf-terms-btn--cancel:focus-visible {
  background: #c8c8c8;
  outline: none;
}

@media (max-width: 560px) {
  .pdf-terms-overlay {
    padding: 12px;
  }

  .pdf-terms-modal__header {
    padding: 16px 44px 12px 18px;
  }

  .pdf-terms-modal__title {
    font-size: 15px;
  }

  .pdf-terms-modal__body {
    padding: 14px 18px;
    font-size: 13px;
  }

  .pdf-terms-modal__actions {
    padding: 12px 18px 14px;
    flex-direction: column-reverse;
  }

  .pdf-terms-btn {
    width: 100%;
    min-width: 0;
  }
}
