/* ===========================================================
   Legal & footer pages — shared design system
   Used by: pages/terms, pages/privacy, pages/refund, pages/sitemap
   Aligned with home-v2 palette + Manrope (global-font.css)
   =========================================================== */

:root {
    --lp-ink: #000000;
    --lp-ink-soft: #232830;
    --lp-muted: #6b7280;
    --lp-muted-2: #9ca3af;
    --lp-accent: #5841c0;
    --lp-accent-soft: #ede9fb;
    --lp-blue: #0A8CFF;
    --lp-blue-soft: #E6F3FF;
    --lp-surface: #ffffff;
    --lp-surface-2: #f8f9fa;
    --lp-surface-3: #f3f4f6;
    --lp-border: #e5e7eb;
    --lp-border-2: #d1d5db;
    --lp-radius-sm: 8px;
    --lp-radius: 16px;
    --lp-radius-lg: 24px;
    --lp-radius-pill: 999px;
    --lp-shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.06);
    --lp-shadow: 0 12px 32px -10px rgba(0, 0, 0, 0.18);
    --lp-shadow-hero: 0 30px 80px -40px rgba(10, 10, 10, 0.55);
}

/* Page wrapper */
.lp-page {
    background: var(--lp-surface-2);
    color: var(--lp-ink-soft);
    padding-bottom: 96px;
}

.lp-page * {
    box-sizing: border-box;
}

/* ---------- Hero ---------- */
.lp-hero {
    position: relative;
    background: var(--lp-ink);
    color: #fff;
    padding: 88px 24px 64px;
    overflow: hidden;
    border-radius: 0 0 var(--lp-radius-lg) var(--lp-radius-lg);
    box-shadow: var(--lp-shadow-hero);
}

.lp-hero::before,
.lp-hero::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.55;
    pointer-events: none;
}

.lp-hero::before {
    width: 460px;
    height: 460px;
    top: -200px;
    right: -120px;
    background: radial-gradient(circle, rgba(88, 65, 192, 0.5), transparent 70%);
}

.lp-hero::after {
    width: 360px;
    height: 360px;
    bottom: -180px;
    left: -100px;
    background: radial-gradient(circle, rgba(10, 140, 255, 0.35), transparent 70%);
}

.lp-hero__inner {
    position: relative;
    max-width: 1080px;
    margin: 0 auto;
    z-index: 2;
}

.lp-hero__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border: 1px solid rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.06);
    border-radius: var(--lp-radius-pill);
    color: #d1d5db;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    backdrop-filter: blur(6px);
}

.lp-hero__eyebrow .dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #22c55e;
    box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.18);
}

.lp-hero__title {
    margin: 18px 0 12px;
    font-size: clamp(36px, 6vw, 60px);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.05;
    color: #fff;
}

.lp-hero__lede {
    max-width: 720px;
    color: #cbd5e1;
    font-size: clamp(15px, 1.4vw, 18px);
    line-height: 1.6;
    margin: 0 0 24px;
}

.lp-hero__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 22px;
    margin-bottom: 28px;
    color: #94a3b8;
    font-size: 14px;
}

.lp-hero__meta span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.lp-hero__meta i {
    color: #cbd5e1;
}

/* Tabs inside the hero (terms / refund / privacy) */
.lp-tabs {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 4px;
    padding: 4px;
    border-radius: var(--lp-radius-pill);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.lp-tabs a {
    padding: 10px 22px;
    border-radius: var(--lp-radius-pill);
    color: #e5e7eb;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.25s ease;
}

.lp-tabs a:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
}

.lp-tabs a.is-active {
    background: #fff;
    color: var(--lp-ink);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
}

/* ---------- Body layout ---------- */
.lp-body {
    max-width: 1180px;
    margin: -32px auto 0;
    padding: 0 24px;
    position: relative;
    z-index: 3;
}

.lp-grid {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 32px;
    align-items: start;
}

@media (max-width: 991px) {
    .lp-grid {
        grid-template-columns: 1fr;
    }
}

/* Sticky table of contents */
.lp-toc {
    position: sticky;
    top: 96px;
    background: var(--lp-surface);
    border: 1px solid var(--lp-border);
    border-radius: var(--lp-radius);
    padding: 18px 18px 14px;
    box-shadow: var(--lp-shadow-sm);
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}

.lp-toc__title {
    margin: 0 0 12px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--lp-muted);
}

.lp-toc__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.lp-toc__list a {
    display: block;
    padding: 8px 12px;
    border-radius: 10px;
    color: var(--lp-ink-soft);
    font-size: 13.5px;
    font-weight: 500;
    text-decoration: none;
    line-height: 1.4;
    transition: all 0.2s ease;
    border-left: 2px solid transparent;
}

.lp-toc__list a:hover {
    background: var(--lp-surface-3);
    color: var(--lp-ink);
}

.lp-toc__list a.is-active {
    background: var(--lp-accent-soft);
    color: var(--lp-accent);
    border-left-color: var(--lp-accent);
    font-weight: 600;
}

.lp-toc__group + .lp-toc__group {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px dashed var(--lp-border);
}

@media (max-width: 991px) {
    .lp-toc {
        position: static;
        max-height: none;
    }
}

/* Prose card */
.lp-prose {
    background: var(--lp-surface);
    border: 1px solid var(--lp-border);
    border-radius: var(--lp-radius-lg);
    padding: clamp(28px, 4vw, 56px);
    box-shadow: var(--lp-shadow-sm);
    color: var(--lp-ink-soft);
    line-height: 1.75;
    font-size: 16px;
}

.lp-section + .lp-section {
    margin-top: 48px;
    padding-top: 40px;
    border-top: 1px solid var(--lp-border);
}

.lp-section__kicker {
    display: inline-block;
    padding: 4px 12px;
    border-radius: var(--lp-radius-pill);
    background: var(--lp-blue-soft);
    color: var(--lp-blue);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 14px;
}

.lp-prose h1 {
    font-size: clamp(28px, 3.4vw, 38px);
    font-weight: 800;
    color: var(--lp-ink);
    letter-spacing: -0.015em;
    line-height: 1.15;
    margin: 0 0 14px;
}

.lp-prose h2 {
    font-size: 22px;
    font-weight: 700;
    color: var(--lp-ink);
    letter-spacing: -0.005em;
    margin: 36px 0 12px;
    scroll-margin-top: 110px;
}

.lp-prose h3 {
    font-size: 17px;
    font-weight: 700;
    color: var(--lp-ink);
    margin: 26px 0 10px;
    scroll-margin-top: 110px;
}

.lp-prose p {
    margin: 0 0 16px;
    color: var(--lp-ink-soft);
}

.lp-prose b,
.lp-prose strong {
    color: var(--lp-ink);
    font-weight: 700;
}

.lp-prose i,
.lp-prose em {
    color: var(--lp-muted);
}

.lp-prose ul,
.lp-prose ol {
    margin: 0 0 18px;
    padding-left: 22px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.lp-prose ul li {
    list-style: disc;
}

.lp-prose ol li {
    list-style: decimal;
}

.lp-prose a {
    color: var(--lp-accent);
    text-decoration: none;
    border-bottom: 1px solid rgba(88, 65, 192, 0.3);
    transition: all 0.2s ease;
}

.lp-prose a:hover {
    color: var(--lp-ink);
    border-bottom-color: var(--lp-ink);
}

.lp-prose hr {
    border: none;
    border-top: 1px solid var(--lp-border);
    margin: 32px 0;
}

/* Effective-date callout above prose */
.lp-effective {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
    border-radius: var(--lp-radius-pill);
    background: var(--lp-surface-3);
    border: 1px solid var(--lp-border);
    color: var(--lp-muted);
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 28px;
}

.lp-effective i {
    color: var(--lp-accent);
}

/* Contact card at the end of legal pages */
.lp-contact {
    margin-top: 48px;
    padding: 28px 28px;
    border-radius: var(--lp-radius);
    background: linear-gradient(180deg, #000000, #1a1a25);
    color: #e5e7eb;
    display: flex;
    flex-wrap: wrap;
    gap: 16px 28px;
    align-items: center;
    justify-content: space-between;
}

.lp-contact h3 {
    margin: 0 0 4px;
    color: #fff;
    font-size: 18px;
    font-weight: 700;
}

.lp-contact p {
    margin: 0;
    color: #cbd5e1;
    font-size: 14px;
    line-height: 1.55;
}

.lp-contact a.lp-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 22px;
    background: #fff;
    color: var(--lp-ink);
    border-radius: var(--lp-radius-pill);
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    transition: all 0.25s ease;
}

.lp-contact a.lp-btn:hover {
    background: var(--lp-accent);
    color: #fff;
    transform: translateY(-1px);
}

/* ---------- Sitemap-specific ---------- */
.lp-sitemap-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    margin-top: 8px;
}

@media (max-width: 720px) {
    .lp-sitemap-grid {
        grid-template-columns: 1fr;
    }
}

.lp-card {
    background: var(--lp-surface);
    border: 1px solid var(--lp-border);
    border-radius: var(--lp-radius);
    padding: 26px 26px 22px;
    transition: all 0.25s ease;
}

.lp-card:hover {
    border-color: var(--lp-ink);
    box-shadow: var(--lp-shadow);
    transform: translateY(-2px);
}

.lp-card__head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.lp-card__icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--lp-accent-soft);
    color: var(--lp-accent);
    font-size: 18px;
}

.lp-card__title {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: var(--lp-ink);
    letter-spacing: -0.005em;
}

.lp-card__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.lp-card__list a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 10px;
    color: var(--lp-ink-soft);
    text-decoration: none;
    font-size: 14.5px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.lp-card__list a::before {
    content: "›";
    color: var(--lp-muted-2);
    font-weight: 700;
    transition: all 0.2s ease;
}

.lp-card__list a:hover {
    background: var(--lp-surface-3);
    color: var(--lp-accent);
}

.lp-card__list a:hover::before {
    color: var(--lp-accent);
    transform: translateX(2px);
}

/* Blog posts grid (sitemap bottom) */
.lp-posts {
    margin-top: 48px;
}

.lp-posts__head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 18px;
}

.lp-posts__title {
    margin: 0;
    font-size: 24px;
    font-weight: 800;
    color: var(--lp-ink);
    letter-spacing: -0.01em;
}

.lp-posts__count {
    color: var(--lp-muted);
    font-size: 13px;
    font-weight: 500;
}

.lp-posts__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

@media (max-width: 900px) {
    .lp-posts__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 560px) {
    .lp-posts__grid {
        grid-template-columns: 1fr;
    }
}

.lp-posts__col {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.lp-post {
    background: var(--lp-surface);
    border: 1px solid var(--lp-border);
    border-radius: 12px;
    padding: 14px 16px;
    transition: all 0.2s ease;
}

.lp-post:hover {
    border-color: var(--lp-ink);
    box-shadow: var(--lp-shadow-sm);
}

.lp-post a {
    color: var(--lp-ink-soft);
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    line-height: 1.45;
    display: block;
}

.lp-post:hover a {
    color: var(--lp-accent);
}

/* Pagination */
.lp-pagination {
    margin-top: 28px;
    display: flex;
    justify-content: center;
}

.lp-pagination .pagination {
    gap: 4px;
}

.lp-pagination .page-link {
    color: var(--lp-ink-soft);
    border: 1px solid var(--lp-border);
    border-radius: 10px !important;
    margin: 0 2px;
    font-weight: 600;
}

.lp-pagination .page-item.active .page-link {
    background: var(--lp-ink);
    border-color: var(--lp-ink);
    color: #fff;
}

/* Print friendly */
@media print {
    .lp-hero,
    .lp-toc,
    .lp-contact {
        display: none !important;
    }
    .lp-prose {
        border: none;
        box-shadow: none;
        padding: 0;
    }
    .lp-page {
        background: #fff;
        padding: 0;
    }
}
