/* ═══════════════════════════════════════
   MPLATS V2 — 정책 페이지 공통
   적용: /v2/company, /v2/terms,
        /v2/privacy, /v2/refund
   ═══════════════════════════════════════ */
* { box-sizing: border-box; }
html, body {
    margin: 0;
    padding: 0;
}
body {
    font-family: 'Pretendard', -apple-system, 'Noto Sans KR', 'Malgun Gothic', sans-serif;
}

.policy-page {
    min-height: 100vh;
    background: #f8fafc;
    color: #0f172a;
    display: flex;
    flex-direction: column;
}

/* ─── 헤더 ─── */
.policy-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 32px;
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
    position: sticky;
    top: 0;
    z-index: 50;
}
.policy-logo img {
    height: 28px;
    vertical-align: middle;
}
.policy-header-nav {
    display: flex;
    gap: 8px;
    align-items: center;
}
.policy-header-link {
    font-size: 13px;
    color: #475569;
    text-decoration: none;
    padding: 6px 14px;
    border-radius: 6px;
    transition: background .15s, color .15s;
    background: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
}
.policy-header-link:hover {
    background: #f1f5f9;
    color: #1e293b;
}

/* ─── 컨테이너 ─── */
.policy-container {
    flex: 1;
    width: 100%;
    max-width: 960px;
    margin: 40px auto;
    padding: 0 24px;
}

/* ─── 카드 ─── */
.policy-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 40px;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

/* ─── 타이틀 ─── */
.policy-title {
    font-size: 28px;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #0f172a;
    margin: 0 0 8px;
}
.policy-subtitle {
    font-size: 14px;
    color: #64748b;
    line-height: 1.7;
    margin: 0 0 32px;
}
.policy-effective {
    display: inline-block;
    background: #f1f5f9;
    color: #475569;
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 6px;
    margin-bottom: 24px;
    font-weight: 500;
}

/* ─── 정의 테이블 ─── */
.policy-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 0 24px;
    font-size: 14px;
    color: #1e293b;
    border-top: 2px solid #0f172a;
}
.policy-table th, .policy-table td {
    padding: 14px 18px;
    border-bottom: 1px solid #f1f5f9;
    text-align: left;
    vertical-align: top;
}
.policy-table th {
    background: #f8fafc;
    color: #475569;
    font-weight: 600;
    width: 140px;
    white-space: nowrap;
}

/* 사업자 정보 페이지 — col 너비 */
.policy-col-label {
    width: 160px;
}
.policy-table-company th {
    width: 160px;
}
.policy-table td a {
    color: #6d28d9;
    text-decoration: none;
}
.policy-table td a:hover {
    text-decoration: underline;
}

/* ─── 섹션 (약관/방침 전문) ─── */
.policy-section {
    margin-bottom: 28px;
    scroll-margin-top: 80px;
}
.policy-section-title {
    font-size: 16px;
    font-weight: 700;
    color: #0f172a;
    padding-bottom: 8px;
    border-bottom: 2px solid #e2e8f0;
    margin: 0 0 14px;
}
.policy-section p {
    font-size: 14px;
    line-height: 1.8;
    color: #334155;
    margin: 0 0 10px;
}
.policy-section ol,
.policy-section ul {
    padding-left: 22px;
    margin: 8px 0;
    color: #334155;
    line-height: 1.8;
    font-size: 14px;
}
.policy-section ol li,
.policy-section ul li {
    padding: 3px 0;
}

/* ─── 본문 표 (개인정보 항목 등) ─── */
.policy-data-table {
    width: 100%;
    border-collapse: collapse;
    margin: 8px 0 16px;
    font-size: 13px;
}
.policy-data-table th,
.policy-data-table td {
    border: 1px solid #e2e8f0;
    padding: 10px 12px;
    text-align: left;
    vertical-align: top;
}
.policy-data-table th {
    background: #f8fafc;
    font-weight: 600;
    color: #475569;
}

/* ─── 강조 인라인 링크 (조문 본문 내) ─── */
.policy-link-emphasis {
    color: #6d28d9;
    font-weight: 600;
    text-decoration: none;
}
.policy-link-emphasis:hover {
    text-decoration: underline;
}

/* ─── TOC (좌측 목차) ─── */
.policy-with-toc {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 32px;
    align-items: start;
}
.policy-toc {
    position: sticky;
    top: 80px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 16px;
    max-height: calc(100vh - 100px);
    overflow-y: auto;
}
.policy-toc-title {
    font-size: 12px;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 10px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
}
.policy-toc ul {
    list-style: none;
    padding: 0;
    margin: 0;
}
.policy-toc li {
    padding: 0;
}
.policy-toc a {
    display: block;
    font-size: 13px;
    color: #475569;
    text-decoration: none;
    padding: 5px 10px;
    border-radius: 6px;
    transition: background .15s, color .15s;
    border-left: 2px solid transparent;
}
.policy-toc a:hover {
    background: #f1f5f9;
    color: #0f172a;
}
.policy-toc a.active {
    background: #f5f3ff;
    color: #6d28d9;
    font-weight: 600;
    border-left-color: #6d28d9;
}

/* 본문 article */
.policy-articles {
    min-width: 0;
}

/* ─── 빠른 링크 (페이지 하단) ─── */
.policy-quick-links {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 28px;
    padding-top: 20px;
    border-top: 1px solid #f1f5f9;
}
.policy-quick-links a {
    font-size: 13px;
    color: #6d28d9;
    text-decoration: none;
    padding: 7px 14px;
    background: #f5f3ff;
    border-radius: 6px;
    transition: background .15s;
    font-weight: 500;
}
.policy-quick-links a:hover {
    background: #ede9fe;
}

/* ─── 보조 카드(공지 등) ─── */
.policy-callout {
    background: #f5f3ff;
    border: 1px solid #ddd6fe;
    border-radius: 10px;
    padding: 14px 18px;
    margin: 16px 0;
    font-size: 13px;
    color: #4c1d95;
    line-height: 1.7;
}
.policy-callout strong {
    color: #5b21b6;
}

/* ─── 반응형 ─── */
@media (max-width: 768px) {
    .policy-header {
        padding: 12px 16px;
    }
    .policy-container {
        margin: 20px auto;
        padding: 0 16px;
    }
    .policy-card {
        padding: 24px 20px;
    }
    .policy-title {
        font-size: 22px;
    }
    .policy-table th {
        width: 100px;
        padding: 12px 10px;
        font-size: 13px;
    }
    .policy-table td {
        padding: 12px;
        font-size: 13px;
    }
    .policy-with-toc {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .policy-toc {
        position: static;
        max-height: 240px;
    }
}
