/* ============================================
   제증명서류발급 안내 모달 (certificate-issuance-modal)
   푸터 링크 클릭 시 표시 — 수면진정마취 모달과 동일 UI 톤
   ============================================ */
.certificate-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 10000;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.certificate-modal.active { display: flex; }

.certificate-modal .cert-dim {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
}

.certificate-modal .cert-inner {
  position: relative;
  background: #fff;
  border-radius: 16px;
  max-width: 640px;
  width: 100%;
  max-height: 88vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: certNoticeIn 0.3s ease;
}
@keyframes certNoticeIn {
  from { opacity: 0; transform: translateY(-15px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* 헤더 */
.certificate-modal .cert-header {
  background: linear-gradient(135deg, #0c4a6e, #075985);
  color: #fff;
  padding: 24px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-radius: 16px 16px 0 0;
  position: sticky;
  top: 0;
  z-index: 1;
}
.certificate-modal .cert-header-left {
  display: flex;
  align-items: center;
  gap: 14px;
}
.certificate-modal .cert-header-icon {
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.certificate-modal .cert-header-icon .material-symbols-outlined { font-size: 26px; }
.certificate-modal .cert-header h2 {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.3px;
  margin: 0 0 2px;
  color: #fff;
}
.certificate-modal .cert-header .cert-sub {
  font-size: 12px;
  opacity: 0.85;
  font-weight: 400;
}
.certificate-modal .cert-close {
  background: rgba(255, 255, 255, 0.15);
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
  flex-shrink: 0;
}
.certificate-modal .cert-close:hover { background: rgba(255, 255, 255, 0.25); }

/* 본문 */
.certificate-modal .cert-body {
  padding: 28px;
  background: #fff;
}
.certificate-modal .cert-intro {
  font-size: 14px;
  line-height: 1.8;
  color: #374151;
  margin: 0 0 24px;
  word-break: keep-all;
  overflow-wrap: anywhere;
}

/* 섹션 */
.certificate-modal .cert-section { margin-bottom: 28px; }
.certificate-modal .cert-section:last-child { margin-bottom: 0; }
.certificate-modal .cert-section-title {
  font-size: 15px;
  font-weight: 700;
  color: #0c4a6e;
  margin-bottom: 12px;
  padding-left: 12px;
  position: relative;
  word-break: keep-all;
}
.certificate-modal .cert-section-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 3px;
  bottom: 3px;
  width: 4px;
  border-radius: 2px;
  background: linear-gradient(135deg, #0c4a6e, #075985);
}

/* 수수료 표 */
.certificate-modal .cert-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  border: 1px solid #e5e8eb;
  border-radius: 8px;
  overflow: hidden;
}
.certificate-modal .cert-table th,
.certificate-modal .cert-table td {
  padding: 11px 14px;
  border: 1px solid #e5e8eb;
  text-align: left;
  vertical-align: middle;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
.certificate-modal .cert-table thead th {
  background: #f1f5f9;
  color: #334155;
  font-weight: 700;
  text-align: center;
}
.certificate-modal .cert-table td {
  color: #374151;
  line-height: 1.6;
}
.certificate-modal .cert-table td:last-child {
  text-align: center;
  white-space: nowrap;
  font-weight: 600;
  color: #0c4a6e;
  width: 34%;
}
.certificate-modal .cert-table tbody tr:nth-child(even) td { background: #fafbfc; }

/* 안내 리스트 (주의사항) */
.certificate-modal .cert-notes {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
}
.certificate-modal .cert-notes li {
  position: relative;
  padding-left: 16px;
  font-size: 12.5px;
  line-height: 1.7;
  color: #6b7280;
  margin-bottom: 7px;
  word-break: keep-all;
  overflow-wrap: anywhere;
}
.certificate-modal .cert-notes li:last-child { margin-bottom: 0; }
.certificate-modal .cert-notes li::before {
  content: "※";
  position: absolute;
  left: 0;
  top: 0;
  color: #9ca3af;
  font-size: 11px;
}

/* 푸터 */
.certificate-modal .cert-footer {
  background: #f9fafb;
  border-top: 1px solid #e5e8eb;
  padding: 18px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-radius: 0 0 16px 16px;
  position: sticky;
  bottom: 0;
}
.certificate-modal .cert-footer-text {
  font-size: 11px;
  color: #6b7280;
  line-height: 1.5;
  display: flex;
  align-items: center;
  gap: 6px;
}
.certificate-modal .cert-footer-text .material-symbols-outlined { font-size: 16px; color: #9ca3af; flex-shrink: 0; }
.certificate-modal .cert-confirm-btn {
  padding: 11px 22px;
  background: linear-gradient(135deg, #075985, #0c4a6e);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  transition: background 0.15s;
  font-family: inherit;
}
.certificate-modal .cert-confirm-btn:hover {
  background: linear-gradient(135deg, #0c4a6e, #082f49);
}

/* 모바일 반응형 */
@media (max-width: 600px) {
  .certificate-modal .cert-inner { max-height: 95vh; }
  .certificate-modal .cert-header { padding: 18px 20px; }
  .certificate-modal .cert-header h2 { font-size: 16px; }
  .certificate-modal .cert-body { padding: 20px; }
  .certificate-modal .cert-table { font-size: 12px; }
  .certificate-modal .cert-table th,
  .certificate-modal .cert-table td { padding: 9px 10px; }
  .certificate-modal .cert-footer { flex-direction: column; padding: 14px 20px; }
  .certificate-modal .cert-confirm-btn { width: 100%; justify-content: center; }
}
