/*
 * tapsight 이용약관 · 개인정보처리방침 — 팝업(모달) + 본문 서식 (2026-10-29)
 *  - 푸터의 [data-legal="terms|privacy"] 링크 클릭 → 팝업. JS 없이 열면 terms.html / privacy.html 로 이동
 *  - 문의 모달(.iq-modal)과 같은 톤 : 네이비 블러 배경 · 흰 패널 · 둥근 모서리
 */
.lg-modal{position:fixed;inset:0;z-index:1300;display:none;align-items:center;justify-content:center;padding:24px 16px}
.lg-modal.is-open{display:flex}
.lg-backdrop{position:absolute;inset:0;background:rgba(7,26,59,.55);backdrop-filter:blur(6px);-webkit-backdrop-filter:blur(6px);opacity:0;transition:opacity .25s ease}
.lg-modal.is-open .lg-backdrop{opacity:1}
.lg-panel{position:relative;width:min(860px,100%);max-height:calc(100vh - 48px);display:flex;flex-direction:column;border:1px solid rgba(255,255,255,.9);border-radius:28px;background:#fff;box-shadow:0 40px 90px rgba(8,34,83,.35);opacity:0;transform:translateY(18px) scale(.985);transition:opacity .3s ease,transform .35s cubic-bezier(.2,.72,.25,1);overflow:hidden}
.lg-modal.is-open .lg-panel{opacity:1;transform:none}
.lg-bar{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:16px 18px 14px 26px;border-bottom:1px solid #eef1f8}
.lg-bar b{display:inline-flex;align-items:center;gap:8px;color:var(--navy,#071a3b);font-size:13px;font-weight:800;letter-spacing:.02em}
.lg-bar b:before{content:"";width:7px;height:7px;border-radius:50%;background:linear-gradient(135deg,var(--blue,#2E5BFC),var(--mint,#4ed4d1))}
.lg-tools{display:flex;align-items:center;gap:6px}
.lg-tools a,.lg-tools button{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:34px;padding:0 12px;border:1px solid #e2e8f6;border-radius:999px;background:#fff;color:#39435f;font:inherit;font-size:12px;font-weight:700;cursor:pointer;text-decoration:none;transition:background .2s,color .2s}
.lg-tools a:hover,.lg-tools button:hover{background:#E7EDFF;color:var(--blue-deep,#0D3FF2);text-decoration:none}
.lg-tools .lg-x{width:34px;padding:0;font-size:16px;line-height:1}
.lg-body{overflow:auto;padding:28px 30px 34px;background:#fff;-webkit-overflow-scrolling:touch}
.lg-loading{display:grid;place-items:center;min-height:220px;color:#8b96b4;font-size:13.5px;font-weight:600}
.lg-loading i{width:28px;height:28px;margin-bottom:12px;border:3px solid #E7EDFF;border-top-color:var(--blue,#2E5BFC);border-radius:50%;animation:lg-spin .8s linear infinite}
@keyframes lg-spin{to{transform:rotate(360deg)}}
body.lg-modal-open{overflow:hidden}

/* ───── 본문 서식 (팝업 · 독립 페이지 공용) ───── */
.lg-doc{color:#3d4a6b;font-size:14px;line-height:1.8;letter-spacing:-.005em;word-break:keep-all}
.lg-doc>*:first-child{margin-top:0}
.lg-head{margin:0 0 22px;padding:0 0 22px;border-bottom:1px solid #e6eaf4}
.lg-head .lg-kicker{display:inline-flex;align-items:center;gap:8px;margin:0 0 10px;color:var(--blue-deep,#0D3FF2);font-size:12px;font-weight:800;letter-spacing:.08em;text-transform:uppercase}
.lg-head .lg-kicker:before{content:"";width:7px;height:7px;border-radius:50%;background:linear-gradient(135deg,var(--blue,#2E5BFC),var(--mint,#4ed4d1))}
.lg-head h1{margin:0;color:var(--navy,#071a3b);font-size:26px;font-weight:800;line-height:1.3;letter-spacing:-.02em}
.lg-head .lg-date{margin:10px 0 0;color:#7a8399;font-size:13px;font-weight:600}
.lg-doc .lg-lead{margin:0 0 20px;color:#4a5578;font-size:14.5px}
.lg-doc h2{position:relative;margin:36px 0 14px;padding-left:14px;color:var(--navy,#071a3b);font-size:17px;font-weight:800;line-height:1.4;letter-spacing:-.015em}
.lg-doc h2:before{content:"";position:absolute;left:0;top:4px;bottom:4px;width:4px;border-radius:4px;background:linear-gradient(180deg,var(--blue,#2E5BFC),var(--mint,#4ed4d1))}
.lg-doc h3{margin:26px 0 10px;color:var(--navy,#071a3b);font-size:15px;font-weight:700;line-height:1.5}
.lg-doc h4{margin:18px 0 8px;color:#39435f;font-size:13.5px;font-weight:700}
.lg-doc p{margin:0 0 12px}
.lg-doc ol,.lg-doc ul{margin:0 0 14px;padding-left:22px}
.lg-doc ol>li,.lg-doc ul>li{margin:0 0 6px;padding-left:4px}
.lg-doc ol>li::marker{color:var(--blue-deep,#0D3FF2);font-weight:700}
.lg-doc ul>li::marker{color:#9aa6c4}
.lg-doc li>ul{margin:8px 0 4px;padding-left:18px}
.lg-doc li>ul>li{margin-bottom:4px}
.lg-doc .lg-note{margin:0 0 16px;padding:14px 16px;border-radius:14px;background:#F4F7FF;color:#4a5578;font-size:13px;line-height:1.75}
.lg-doc .lg-info{display:grid;grid-template-columns:auto 1fr;gap:6px 18px;margin:0 0 22px;padding:16px 20px;border:1px solid #e6eaf4;border-radius:16px;background:#F8FAFF;font-size:13.5px}
.lg-doc .lg-info b{color:#7a8399;font-weight:600;white-space:nowrap}
.lg-doc .lg-info span{color:var(--navy,#071a3b);font-weight:600}
.lg-doc .lg-table{margin:0 0 16px;overflow:auto;border:1px solid #e6eaf4;border-radius:14px}
.lg-doc table{width:100%;border-collapse:collapse;font-size:13px;line-height:1.6}
.lg-doc th,.lg-doc td{padding:11px 14px;border-bottom:1px solid #e6eaf4;text-align:left;vertical-align:top}
.lg-doc th{background:#F4F7FF;color:var(--navy,#071a3b);font-weight:700;white-space:nowrap}
.lg-doc tr:last-child td{border-bottom:0}
.lg-doc td:first-child{color:var(--navy,#071a3b);font-weight:600}
.lg-doc a{color:var(--blue-deep,#0D3FF2);font-weight:700;text-decoration:underline;text-underline-offset:3px}
.lg-doc .lg-addendum{margin-top:36px;padding-top:20px;border-top:1px solid #e6eaf4}
.lg-doc .lg-foot{margin:28px 0 0;color:#8b96b4;font-size:12.5px}

/* 독립 페이지 (terms.html · privacy.html) */
.lg-page{padding:36px 0 80px}
.lg-page .lg-card{max-width:860px;margin:0 auto;padding:40px 44px 48px;border:1px solid rgba(255,255,255,.9);border-radius:28px;background:#fff;box-shadow:0 30px 70px rgba(8,34,83,.08)}
@media (max-width:760px){
  .lg-modal{padding:0}
  .lg-panel{width:100%;max-height:100vh;max-height:100dvh;border-radius:0;border:0}
  .lg-bar{padding:14px 12px 12px 18px}
  .lg-body{padding:20px 18px 28px}
  .lg-head h1{font-size:22px}
  .lg-doc h2{font-size:16px}
  .lg-doc .lg-info{grid-template-columns:1fr;gap:2px;padding:14px 16px}
  .lg-doc .lg-info b{margin-top:8px}
  .lg-doc .lg-info b:first-child{margin-top:0}
  .lg-doc th,.lg-doc td{padding:9px 10px}
  .lg-doc th{white-space:normal}
  .lg-page{padding:20px 0 60px}
  .lg-page .lg-card{padding:26px 20px 32px;border-radius:20px}
}
