/* Sidebar CSS */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: var(--space-section-gap);
}

@media(min-width: 900px) {
    .sidebar {
        padding-left: 2rem;
        border-left: 1px solid var(--border);
    }
}

.sidebar-section, .widget {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: var(--space-card-pad);
    margin-bottom: 0;
}

.sidebar-title, .widget h3 {
    font-size: 1.1rem;
    font-weight: 800;
    margin-bottom: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primary);
}

.widget p { font-size: 0.9rem; color: var(--muted); margin-bottom: 1.2rem; }

.widget input[type="email"] {
    width: 100%;
    padding: 0.8rem 1rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg-secondary);
    color: var(--text);
    margin-bottom: 1rem;
    outline: none;
    transition: var(--transition);
}

.widget input[type="email"]:focus { border-color: var(--primary); }

/* Footer */
.site-footer {
    margin-top: calc(var(--space-section-gap) * 2.5);
    padding: 2.5rem 0 3rem;
    border-top: 1px solid var(--border);
    background: linear-gradient(180deg, transparent 0%, rgba(99, 102, 241, 0.03) 100%);
}

.site-footer-inner {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 2rem;
}

.site-footer-copy {
    display: grid;
    gap: 0.35rem;
}

.site-footer-brand {
    font-family: 'Outfit', sans-serif;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
}

.site-footer-meta,
.site-footer-note {
    color: var(--muted);
    font-size: 0.92rem;
}

.site-footer-legal {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.75rem 1rem;
}

.site-footer-link {
    color: var(--muted);
    font-size: 0.92rem;
    font-weight: 600;
}

.site-footer-link:hover,
.site-footer-link:focus-visible {
    color: var(--text);
}

.site-footer-link.is-active {
    color: var(--text);
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 0.2rem;
}

.legal-shell {
    padding-top: var(--space-shell-top);
}

.legal-page {
    padding-bottom: 1rem;
}

.legal-header {
    margin-bottom: 2rem;
}

.legal-kicker {
    margin-bottom: 0.85rem;
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.legal-lead {
    max-width: 65ch;
    color: var(--muted);
    font-size: 1.05rem;
}

.legal-card {
    margin-bottom: var(--space-section-gap);
    padding: var(--space-card-pad);
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow);
}

.legal-card h2 {
    margin-bottom: 0.75rem;
    font-size: 1.2rem;
}

.legal-card p {
    color: var(--text);
}

.legal-card-warning {
    border-color: rgba(245, 158, 11, 0.35);
    background: linear-gradient(180deg, rgba(245, 158, 11, 0.08) 0%, rgba(245, 158, 11, 0.03) 100%);
}

.legal-status {
    display: inline-grid;
    gap: 0.15rem;
    margin-top: 1.5rem;
    padding: 0.9rem 1rem;
    border-radius: 16px;
    border: 1px solid var(--border);
    background: var(--card);
    box-shadow: var(--shadow);
}

.legal-status strong {
    font-size: 0.95rem;
}

.legal-status span {
    color: var(--muted);
    font-size: 0.9rem;
}

.legal-status.is-complete {
    border-color: rgba(34, 197, 94, 0.28);
}

.legal-status.is-incomplete {
    border-color: rgba(245, 158, 11, 0.35);
}

.legal-definition-list {
    display: grid;
    gap: 1rem;
}

.legal-definition-row {
    display: grid;
    grid-template-columns: minmax(180px, 220px) minmax(0, 1fr);
    gap: 0.75rem 1.25rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
}

.legal-definition-row:first-child {
    padding-top: 0;
    border-top: none;
}

.legal-definition-row dt {
    font-weight: 700;
    color: var(--text);
}

.legal-definition-row dd {
    color: var(--text);
}

.legal-address-lines {
    display: grid;
    gap: 0.2rem;
}

.legal-inline-link {
    color: var(--primary);
    font-weight: 600;
}

.legal-inline-link:hover,
.legal-inline-link:focus-visible {
    color: var(--primary-hover);
}

.legal-footnote {
    margin-top: 1rem;
    color: var(--muted);
    font-size: 0.92rem;
}

.legal-list {
    padding-left: 1.2rem;
    color: var(--text);
}

.legal-list li + li {
    margin-top: 0.6rem;
}

@media (max-width: 720px) {
    .site-footer-inner {
        flex-direction: column;
        align-items: flex-start;
    }

    .site-footer-legal {
        justify-content: flex-start;
    }

    .legal-definition-row {
        grid-template-columns: 1fr;
    }
}

/* Modal CSS moved to header.css as it's included via header.ejs and needs to be global */
