﻿:root {
    --brand-primary: #1d4ed8;
    --brand-secondary: #0f172a;
    --bg: #f9fafb;
    --surface: #ffffff;
    --text-primary: #111827;
    --text-secondary: #6b7280;
    --border-subtle: #e5e7eb;
    --radius: 16px;
    --shadow-soft: 0 20px 40px rgba(2,6,23,.12);
    --shadow-subtle: 0 6px 18px rgba(2,6,23,.08);
}

/* ===== Layout fix ===== */
html, body {
    height: 100%;
}

body {
    display: flex;
    flex-direction: column;
    background: var(--bg);
    color: var(--text-primary);
    font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    line-height: 1.7;
}

html {
    scroll-behavior: smooth;
}

/* ===== SVG safety ===== */
svg {
    max-width: 100%;
    height: auto;
    font-size: initial;
}

.brand-logo img,
.brand-logo svg {
    width: 48px;
    height: 48px;
    display: block;
    flex-shrink: 0;
}

/* ===== Header ===== */
.policy-header {
    background: radial-gradient(1200px 400px at top right, rgba(56,189,248,.25), transparent), linear-gradient(135deg, var(--brand-primary), var(--brand-secondary));
    color: #fff;
    padding: 2.75rem 2.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow-soft);
}

    .policy-header a {
        color: #e0f2fe;
        text-decoration: none;
    }

/* ===== Cards ===== */
.policy-card {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 2.25rem;
    border: 1px solid var(--border-subtle);
    box-shadow: var(--shadow-subtle);
}

/* ===== TOC ===== */
.toc a {
    display: block;
    padding: .45rem .65rem;
    border-radius: 10px;
    color: var(--text-primary);
    text-decoration: none;
}

    .toc a:hover {
        background: #eff6ff;
        color: var(--brand-primary);
    }

    .toc a.active {
        background: #e0e7ff;
        color: var(--brand-primary);
        font-weight: 600;
        position: relative;
    }

        .toc a.active::before {
            content: "";
            position: absolute;
            left: -6px;
            top: 8px;
            bottom: 8px;
            width: 3px;
            background: var(--brand-primary);
            border-radius: 2px;
        }

/* ===== Sections ===== */
main section {
    scroll-margin-top: 140px;
    scroll-margin-bottom: 160px;
}

.section-title {
    margin-top: 2.5rem;
    margin-bottom: .85rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-subtle);
    font-weight: 600;
}

section:first-child .section-title {
    border-top: none;
    margin-top: 0;
    padding-top: 0;
}

section p, section li {
    font-size: .95rem;
    color: #374151;
}

/* ===== Footer ===== */
footer {
    color: var(--text-secondary);
}

/* ===== Cookie banner ===== */
.cookie-banner {
    position: fixed;
    left: 1rem;
    right: 1rem;
    bottom: 1rem;
    max-width: 920px;
    margin: auto;
    z-index: 1050;
}

    .cookie-banner .card {
        border-radius: 18px;
        border: 1px solid var(--border-subtle);
        box-shadow: var(--shadow-soft);
    }

/* ===== Print ===== */
@media print {
    .toc, .cookie-banner, button {
        display: none !important;
    }

    body {
        background: #fff;
    }

    .policy-card {
        box-shadow: none;
        border: none;
        padding: 0;
    }
}
