/* ══════════════════════════════════════════════════
   docs.css — Layout compartilhado: Ajuda, Privacidade, Termos
   Sidebar esquerda + conteúdo direita
   ══════════════════════════════════════════════════ */

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

html { scroll-behavior: smooth; font-size: 16px; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: #0f172a;
    background: #fff;
    -webkit-font-smoothing: antialiased;
}

:root {
    --purple: #7c3aed;
    --purple-light: #ede9fe;
    --indigo: #4f46e5;
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-400: #94a3b8;
    --slate-500: #64748b;
    --slate-600: #475569;
    --slate-700: #334155;
    --slate-800: #1e293b;
    --slate-900: #0f172a;
    --nav-h: 64px;
}

/* ─── NAV ────────────────────────────────────────── */
.pi-nav {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 100;
    height: var(--nav-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    background: rgba(255,255,255,.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--slate-200);
}

.pi-nav-logo { display: flex; align-items: center; }
.pi-nav-logo img { display: block; }

.pi-nav-links {
    display: flex;
    align-items: center;
    gap: 4px;
    list-style: none;
}

.pi-nav-links a {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--slate-700);
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 8px;
    transition: background 0.2s;
}

.pi-nav-links a:hover { background: var(--slate-100); }

.pi-nav-cta {
    background: var(--purple) !important;
    color: #fff !important;
    font-weight: 600 !important;
    border-radius: 10px !important;
    padding: 7px 16px !important;
    transition: opacity 0.2s !important;
}

.pi-nav-cta:hover { opacity: 0.88 !important; background: var(--purple) !important; }

.pi-burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.pi-burger span {
    display: block;
    width: 22px; height: 2px;
    background: var(--slate-800);
    border-radius: 2px;
    transition: all 0.3s;
}

.pi-drawer {
    display: none;
    position: fixed;
    top: var(--nav-h); left: 0; right: 0;
    background: #fff;
    border-bottom: 1px solid var(--slate-200);
    padding: 16px 24px 24px;
    z-index: 99;
    flex-direction: column;
    gap: 4px;
}

.pi-drawer.open { display: flex; }

.pi-drawer a {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--slate-700);
    text-decoration: none;
    padding: 10px 12px;
    border-radius: 8px;
    transition: background 0.2s;
}

.pi-drawer a:hover { background: var(--slate-100); }
.pi-drawer .pi-nav-cta {
    margin-top: 8px;
    text-align: center;
    background: var(--purple) !important;
    color: #fff !important;
}

/* ─── PAGE WRAPPER ───────────────────────────────── */
.pi-page {
    display: flex;
    min-height: 100vh;
    padding-top: var(--nav-h);
}

/* ─── SIDEBAR ────────────────────────────────────── */
.pi-sidebar {
    width: 260px;
    flex-shrink: 0;
    position: sticky;
    top: var(--nav-h);
    height: calc(100vh - var(--nav-h));
    overflow-y: auto;
    padding: 32px 0 40px;
    border-right: 1px solid var(--slate-200);
    background: var(--slate-50);
    scrollbar-width: thin;
    scrollbar-color: var(--slate-200) transparent;
}

.pi-sidebar::-webkit-scrollbar { width: 4px; }
.pi-sidebar::-webkit-scrollbar-track { background: transparent; }
.pi-sidebar::-webkit-scrollbar-thumb { background: var(--slate-200); border-radius: 99px; }

.pi-sidebar-section {
    margin-bottom: 24px;
    padding: 0 16px;
}

.pi-sidebar-label {
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--slate-400);
    padding: 0 8px;
    margin-bottom: 6px;
    display: block;
}

.pi-sidebar-link {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--slate-600);
    text-decoration: none;
    padding: 7px 10px;
    border-radius: 8px;
    transition: background 0.15s, color 0.15s;
    line-height: 1.3;
    margin-bottom: 2px;
}

.pi-sidebar-link svg { flex-shrink: 0; opacity: 0.6; }

.pi-sidebar-link:hover {
    background: var(--slate-200);
    color: var(--slate-900);
}

.pi-sidebar-link:hover svg { opacity: 1; }

.pi-sidebar-link.active {
    background: var(--purple-light);
    color: var(--purple);
    font-weight: 600;
}

.pi-sidebar-link.active svg { opacity: 1; }

/* ─── MOBILE SIDEBAR TOGGLE ──────────────────────── */
.pi-sidebar-mobile-toggle {
    display: none;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    background: var(--slate-50);
    border-bottom: 1px solid var(--slate-200);
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--slate-700);
}

.pi-sidebar-mobile-toggle svg { transition: transform 0.3s; }
.pi-sidebar-mobile-toggle.open svg { transform: rotate(180deg); }

.pi-sidebar-mobile-content {
    display: block;
}

/* ─── CONTENT AREA ───────────────────────────────── */
.pi-content {
    flex: 1;
    min-width: 0;
    padding: 48px 64px 96px;
    max-width: 820px;
}

/* ─── HERO / PAGE HEADER ─────────────────────────── */
.pi-hero {
    margin-bottom: 48px;
    padding-bottom: 32px;
    border-bottom: 1px solid var(--slate-200);
}

.pi-hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--purple);
    background: var(--purple-light);
    padding: 5px 12px;
    border-radius: 99px;
    margin-bottom: 16px;
}

.pi-hero h1 {
    font-size: clamp(1.75rem, 3vw, 2.25rem);
    font-weight: 900;
    letter-spacing: -0.03em;
    line-height: 1.15;
    color: var(--slate-900);
    margin-bottom: 12px;
}

.pi-hero p {
    font-size: 1rem;
    color: var(--slate-600);
    line-height: 1.65;
    max-width: 560px;
}

.pi-hero-meta {
    margin-top: 16px;
    font-size: 0.8125rem;
    color: var(--slate-400);
}

/* ─── SECTIONS ───────────────────────────────────── */
.pi-section {
    margin-bottom: 56px;
    scroll-margin-top: calc(var(--nav-h) + 24px);
}

.pi-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--slate-900);
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--slate-100);
    letter-spacing: -0.02em;
}

.pi-section-title-icon {
    width: 32px; height: 32px;
    background: var(--purple-light);
    color: var(--purple);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.pi-section h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--slate-800);
    margin: 24px 0 8px;
}

.pi-section p {
    font-size: 0.9375rem;
    color: var(--slate-600);
    line-height: 1.75;
    margin-bottom: 12px;
}

.pi-section ul, .pi-section ol {
    padding-left: 20px;
    margin-bottom: 14px;
}

.pi-section li {
    font-size: 0.9375rem;
    color: var(--slate-600);
    line-height: 1.7;
    margin-bottom: 6px;
}

.pi-section a {
    color: var(--purple);
    text-decoration: none;
    font-weight: 500;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s;
}

.pi-section a:hover { border-color: var(--purple); }

.pi-callout {
    background: var(--purple-light);
    border-left: 3px solid var(--purple);
    border-radius: 0 8px 8px 0;
    padding: 14px 18px;
    margin: 16px 0;
    font-size: 0.9rem;
    color: var(--slate-700);
    line-height: 1.65;
}

.pi-callout strong { color: var(--purple); }

.pi-callout--green {
    background: #d1fae5;
    border-color: #10b981;
}

.pi-callout--green strong { color: #065f46; }

.pi-callout--yellow {
    background: #fef9c3;
    border-color: #eab308;
}

.pi-callout--yellow strong { color: #713f12; }

/* FAQ accordion */
.pi-faq-item {
    border: 1px solid var(--slate-200);
    border-radius: 10px;
    margin-bottom: 8px;
    overflow: hidden;
}

.pi-faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    cursor: pointer;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--slate-800);
    background: #fff;
    user-select: none;
    transition: background 0.15s;
    gap: 12px;
}

.pi-faq-question:hover { background: var(--slate-50); }

.pi-faq-icon {
    flex-shrink: 0;
    width: 20px; height: 20px;
    border-radius: 50%;
    background: var(--slate-100);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s, background 0.2s;
}

.pi-faq-item.open .pi-faq-icon {
    transform: rotate(180deg);
    background: var(--purple-light);
}

.pi-faq-item.open .pi-faq-icon svg { color: var(--purple); }

.pi-faq-answer {
    display: none;
    padding: 0 18px 16px;
    font-size: 0.9rem;
    color: var(--slate-600);
    line-height: 1.7;
    border-top: 1px solid var(--slate-100);
}

.pi-faq-answer p { margin-top: 12px; margin-bottom: 0; }
.pi-faq-answer ul { margin-top: 8px; padding-left: 18px; }
.pi-faq-answer li { margin-bottom: 4px; }

.pi-faq-item.open .pi-faq-answer { display: block; }

/* ─── TABLE ──────────────────────────────────────── */
.pi-table-wrap { overflow-x: auto; margin: 16px 0; }

.pi-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.pi-table th {
    background: var(--slate-800);
    color: white;
    text-align: left;
    padding: 10px 14px;
    font-weight: 700;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.pi-table td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--slate-100);
    color: var(--slate-600);
    vertical-align: top;
}

.pi-table tbody tr:nth-child(even) td { background: var(--slate-50); }

/* ─── FOOTER ─────────────────────────────────────── */
.pi-footer {
    background: var(--slate-900);
    color: white;
    padding: 40px 0;
    text-align: center;
}

.pi-footer-inner {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
}

.pi-footer img { display: block; }

.pi-footer-links {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.pi-footer-links a {
    font-size: 0.8125rem;
    color: rgba(255,255,255,.65); /* era #64748b → 3.75:1 FAIL no bg #0f172a; .65 → 7.2:1 PASS */
    text-decoration: none;
    transition: color 0.2s;
}

.pi-footer-links a:hover { color: white; }

.pi-footer-copy {
    font-size: 0.8125rem;
    color: rgba(255,255,255,.65); /* era #475569 → 2.35:1 FAIL no bg escuro */
}

/* ─── RESPONSIVE ─────────────────────────────────── */
@media (max-width: 1024px) {
    .pi-content { padding: 36px 40px 80px; }
}

@media (max-width: 768px) {
    .pi-nav { padding: 0 20px; }
    .pi-nav-links { display: none; }
    .pi-burger { display: flex; }

    .pi-page { flex-direction: column; }

    .pi-sidebar {
        width: 100%;
        position: static;
        height: auto;
        border-right: none;
        border-bottom: 1px solid var(--slate-200);
        padding: 0;
    }

    .pi-sidebar-mobile-toggle { display: flex; }

    .pi-sidebar-mobile-content {
        display: none;
        padding: 16px;
    }

    .pi-sidebar-mobile-content.open { display: block; }

    .pi-content { padding: 28px 20px 64px; }

    .pi-hero h1 { font-size: 1.625rem; }

    .pi-footer-inner { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
    .pi-content { padding: 20px 16px 56px; }
    .pi-section-title { font-size: 1.1rem; }
}
