/* ============================================================
   DingleHome — Legal / policy document layout
   Used by /privacy, /terms, /refunds (loaded after styles.css)
   ============================================================ */

.legal-hero {
    background: var(--grad-brand); color: #fff;
    padding: calc(var(--nav-h) + 56px) 0 56px; position: relative; overflow: hidden;
}
.legal-hero::after {
    content: ''; position: absolute; width: 360px; height: 360px; border-radius: 50%;
    background: rgba(255, 255, 255, 0.08); top: -140px; right: -80px;
}
.legal-hero .eyebrow { background: rgba(255,255,255,0.15); color: #fff; border-color: rgba(255,255,255,0.25); }
.legal-hero .eyebrow::before { background: var(--yellow); box-shadow: 0 0 0 4px rgba(255,193,7,0.25); }
.legal-hero h1 { font-family: var(--font-head); font-size: clamp(2rem, 5vw, 3rem); font-weight: 800; letter-spacing: -0.02em; margin: 16px 0 10px; position: relative; }
.legal-hero p { opacity: 0.92; font-size: 1.05rem; position: relative; }
.legal-hero .updated { display: inline-block; margin-top: 16px; font-size: 0.84rem; font-weight: 600; background: rgba(255,255,255,0.14); padding: 6px 14px; border-radius: var(--r-pill); position: relative; }

/* "In brief" highlight band (privacy page) */
.brief-band { background: var(--surface-2); border-bottom: 1px solid var(--line); padding: 40px 0; }
.brief-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.brief-card { background: #fff; border: 1px solid var(--line); border-radius: var(--r-md); padding: 20px; transition: transform var(--t-fast), box-shadow var(--t-fast); }
.brief-card:hover { transform: translateY(-4px); box-shadow: var(--sh-sm); }
.brief-card .ic { width: 44px; height: 44px; border-radius: 12px; background: var(--mint); display: grid; place-items: center; font-size: 1.25rem; margin-bottom: 12px; }
.brief-card h4 { font-family: var(--font-head); font-size: 1.02rem; color: var(--ink); margin-bottom: 6px; }
.brief-card p { font-size: 0.86rem; color: var(--muted); margin: 0; line-height: 1.55; }
@media (max-width: 880px) { .brief-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .brief-grid { grid-template-columns: 1fr; } }

/* Effective / last-updated meta line */
.legal-meta { display: flex; gap: 18px; flex-wrap: wrap; font-size: 0.86rem; color: var(--muted); margin-bottom: 26px; padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.legal-meta b { color: var(--ink); }

.legal-body { padding: 60px 0 90px; background: var(--surface); }
.legal-layout { display: grid; grid-template-columns: 250px 1fr; gap: 48px; align-items: start; }

/* Table of contents */
.toc { position: sticky; top: calc(var(--nav-h) + 20px); border: 1px solid var(--line); border-radius: var(--r-md); padding: 20px; background: var(--surface-2); }
.toc h4 { font-family: var(--font-head); font-size: 0.82rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.toc ul { display: flex; flex-direction: column; gap: 2px; }
.toc a { display: block; padding: 7px 10px; border-radius: 8px; font-size: 0.9rem; color: var(--text); font-weight: 500; transition: background var(--t-fast), color var(--t-fast); border-left: 2px solid transparent; }
.toc a:hover, .toc a.active { background: var(--mint); color: var(--teal-dark); border-left-color: var(--teal); }

/* Content */
.legal-content { max-width: 760px; }
.legal-content h2 {
    font-family: var(--font-head); font-size: 1.5rem; font-weight: 800; color: var(--ink);
    margin: 40px 0 14px; scroll-margin-top: calc(var(--nav-h) + 20px); display: flex; align-items: center; gap: 12px;
}
.legal-content h2:first-child { margin-top: 0; }
.legal-content h2 .num { font-size: 0.9rem; width: 30px; height: 30px; border-radius: 9px; background: var(--mint); color: var(--teal-dark); display: grid; place-items: center; flex-shrink: 0; }
.legal-content h3 { font-family: var(--font-head); font-size: 1.1rem; color: var(--ink); margin: 22px 0 8px; }
.legal-content p { color: var(--text); margin-bottom: 14px; }
.legal-content ul.bullets { margin: 0 0 16px; padding-left: 4px; display: flex; flex-direction: column; gap: 9px; }
.legal-content ul.bullets li { position: relative; padding-left: 26px; color: var(--text); }
.legal-content ul.bullets li::before { content: ''; position: absolute; left: 6px; top: 10px; width: 7px; height: 7px; border-radius: 50%; background: var(--teal); }
.legal-content a.inline { color: var(--teal-dark); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.legal-content strong { color: var(--ink); }

.callout { display: flex; gap: 14px; background: var(--mint); border: 1px solid rgba(45,149,150,0.25); border-radius: var(--r-md); padding: 16px 18px; margin: 18px 0; }
.callout .ic { font-size: 1.3rem; }
.callout p { margin: 0; font-size: 0.94rem; }

.callout.warn { background: var(--cream); border-color: rgba(255,193,7,0.4); }
.placeholder { background: #FFF3CD; border: 1px dashed #E0A100; color: #6b5200; border-radius: 6px; padding: 1px 7px; font-weight: 700; font-size: 0.9em; }

/* Refund table */
.tbl { width: 100%; border-collapse: collapse; margin: 8px 0 18px; font-size: 0.94rem; border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; }
.tbl th, .tbl td { padding: 13px 16px; text-align: left; border-bottom: 1px solid var(--line); }
.tbl th { background: var(--ink); color: #fff; font-family: var(--font-head); font-weight: 700; font-size: 0.9rem; }
.tbl tr:last-child td { border-bottom: none; }
.tbl tr:nth-child(even) td { background: var(--surface-2); }
.tbl td b { color: var(--teal-dark); }

.legal-foot-cta { margin-top: 44px; padding: 24px; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--r-md); display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; }
.legal-foot-cta p { margin: 0; font-weight: 600; color: var(--ink); }

@media (max-width: 880px) {
    .legal-layout { grid-template-columns: 1fr; }
    .toc { position: static; }
}
