/* ==========================================================================
   Propollo legal pages — shared stylesheet
   Monochrome black & white theme. No build step, no external requests.
   ========================================================================== */

:root {
    --background: #ffffff;
    --foreground: #000000;
    --muted: #4a4a4a;
    --card: #f6f6f6;
    --card-strong: #ebebeb;
    --border: #d6d6d6;
    --accent: #000000;
    --accent-hover: #333333;
    --accent-soft: rgba(0, 0, 0, 0.045);
    --accent-border: rgba(0, 0, 0, 0.18);
    --btn-bg: #000000;
    --btn-fg: #ffffff;
    --header-bg: rgba(255, 255, 255, 0.88);
    --radius: 14px;
    --max: 56rem;
    --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue",
        Arial, "Noto Sans", sans-serif;
    --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
        "Liberation Mono", monospace;
}

@media (prefers-color-scheme: dark) {
    :root {
        --background: #000000;
        --foreground: #ffffff;
        --muted: #a8a8a8;
        --card: #0f0f0f;
        --card-strong: #1a1a1a;
        --border: #2b2b2b;
        --accent: #ffffff;
        --accent-hover: #cccccc;
        --accent-soft: rgba(255, 255, 255, 0.06);
        --accent-border: rgba(255, 255, 255, 0.22);
        --btn-bg: #ffffff;
        --btn-fg: #000000;
        --header-bg: rgba(0, 0, 0, 0.88);
    }
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--background);
    color: var(--muted);
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.7;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    background: var(--header-bg);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
}

.site-header__inner {
    max-width: var(--max);
    margin: 0 auto;
    padding: 0.9rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.brand {
    color: var(--foreground);
    font-weight: 700;
    font-size: 1.05rem;
    text-decoration: none;
    letter-spacing: -0.01em;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}

.site-nav a {
    color: var(--muted);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0.4rem 0.7rem;
    border-radius: 8px;
}

.site-nav a:hover {
    color: var(--foreground);
    background: var(--accent-soft);
}

.site-nav a[aria-current="page"] {
    color: var(--foreground);
    background: var(--accent-soft);
    box-shadow: inset 0 0 0 1px var(--border);
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
    border-bottom: 1px solid var(--border);
    background: var(--background);
}

.hero__inner {
    max-width: var(--max);
    margin: 0 auto;
    padding: 3.25rem 1.25rem 2.5rem;
}

.hero h1 {
    margin: 0 0 0.75rem;
    color: var(--foreground);
    font-size: clamp(1.9rem, 5vw, 2.75rem);
    line-height: 1.15;
    letter-spacing: -0.025em;
    font-weight: 800;
}

.hero p {
    margin: 0;
    font-size: 0.95rem;
    color: var(--muted);
}

/* --------------------------------------------------------------------------
   Layout
   -------------------------------------------------------------------------- */

main {
    max-width: var(--max);
    margin: 0 auto;
    padding: 3rem 1.25rem 4rem;
}

article > section {
    margin-top: 3rem;
    scroll-margin-top: 5rem;
}

article > section:first-child {
    margin-top: 0;
}

h2 {
    margin: 0 0 1rem;
    color: var(--foreground);
    font-size: 1.5rem;
    line-height: 1.3;
    letter-spacing: -0.015em;
    font-weight: 700;
}

h3 {
    margin: 0 0 0.5rem;
    color: var(--foreground);
    font-size: 1.075rem;
    line-height: 1.4;
    font-weight: 600;
}

p {
    margin: 0 0 0.9rem;
}

p:last-child {
    margin-bottom: 0;
}

a {
    color: var(--foreground);
    text-decoration: underline;
    text-decoration-color: var(--accent-border);
    text-underline-offset: 2px;
}

a:hover {
    text-decoration-color: currentColor;
}

strong {
    color: var(--foreground);
    font-weight: 600;
}

code {
    font-family: var(--font-mono);
    font-size: 0.85em;
    background: var(--card-strong);
    color: var(--foreground);
    padding: 0.15em 0.4em;
    border-radius: 5px;
}

ul,
ol {
    margin: 0 0 0.9rem;
    padding-left: 1.35rem;
}

li {
    margin-bottom: 0.35rem;
}

li:last-child {
    margin-bottom: 0;
}

/* --------------------------------------------------------------------------
   Components
   -------------------------------------------------------------------------- */

/* Notice / commitment banner */
.notice {
    margin-bottom: 2.5rem;
    padding: 1.5rem;
    border: 1px solid var(--accent-border);
    background: var(--accent-soft);
    border-radius: var(--radius);
    font-size: 0.9rem;
    line-height: 1.75;
}

.notice p {
    margin: 0 0 0.75rem;
}

.notice p:last-child {
    margin-bottom: 0;
}

.notice__title {
    font-weight: 600;
    color: var(--foreground);
}

/* Table of contents */
.toc {
    margin-bottom: 3rem;
    padding: 1.5rem;
    border: 1px solid var(--border);
    background: var(--card);
    border-radius: var(--radius);
}

.toc h2 {
    margin: 0 0 1rem;
    font-size: 1rem;
    font-weight: 600;
}

.toc ol {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.35rem 1.75rem;
    margin: 0;
    padding-left: 1.35rem;
    font-size: 0.9rem;
}

.toc a {
    color: var(--muted);
    text-decoration: none;
}

.toc a:hover {
    color: var(--foreground);
    text-decoration: underline;
}

@media (min-width: 768px) {
    .toc ol {
        grid-template-columns: 1fr 1fr;
    }
}

/* Card / box */
.card {
    padding: 1.25rem;
    border: 1px solid var(--border);
    background: var(--card);
    border-radius: var(--radius);
}

.card p {
    font-size: 0.9rem;
}

.card--stack > * + * {
    margin-top: 0.4rem;
}

.card--accent {
    border-color: var(--accent-border);
    background: var(--card);
}

/* Sub-section groups (e.g. 2.1, 4.1, 9.1) */
.subsections > * + * {
    margin-top: 1.75rem;
}

.subsections p {
    font-size: 0.95rem;
}

/* Dense helper text */
.text-sm {
    font-size: 0.875rem;
}

.text-xs {
    font-size: 0.775rem;
    line-height: 1.65;
}

.stack > * + * {
    margin-top: 1.5rem;
}

/* CTA row */
.cta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.1rem;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: transparent;
    color: var(--foreground);
    font-size: 0.875rem;
    font-weight: 600;
    text-decoration: none;
}

.btn:hover {
    text-decoration: none;
    border-color: var(--foreground);
}

.btn--primary {
    background: var(--btn-bg);
    border-color: var(--btn-bg);
    color: var(--btn-fg);
}

.btn--primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    color: var(--btn-fg);
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-footer {
    border-top: 1px solid var(--border);
    background: var(--card);
}

.site-footer__inner {
    max-width: var(--max);
    margin: 0 auto;
    padding: 2rem 1.25rem;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
    justify-content: space-between;
    font-size: 0.85rem;
}

.site-footer a {
    color: var(--muted);
    text-decoration: none;
}

.site-footer a:hover {
    color: var(--foreground);
    text-decoration: underline;
}

.site-footer__links {
    display: flex;
    gap: 1.25rem;
    flex-wrap: wrap;
}

/* --------------------------------------------------------------------------
   Print
   -------------------------------------------------------------------------- */

@media print {
    .site-header,
    .cta-row,
    .site-footer {
        display: none;
    }

    body {
        color: #000;
        background: #fff;
    }

    .toc {
        break-inside: avoid;
    }
}
