/* Общие стили статей базы знаний Адвекс — подключать на common, coordinator, manager, mortgage, leader */
:root {
    --bg-page: #0f172a;
    --bg-card: rgba(30, 41, 59, 0.88);
    --accent: #E8501E;
    --accent-light: #FF6B3A;
    --text: #f8fafc;
    --text-muted: #94a3b8;
    --border-subtle: rgba(255, 255, 255, 0.1);
    --container: 1200px;
}
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Onest', system-ui, sans-serif;
    background: var(--bg-page);
    color: var(--text);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}
.bg-grid {
    position: fixed; inset: 0; z-index: 0; pointer-events: none; opacity: 0.04;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.12) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.12) 1px, transparent 1px);
    background-size: 32px 32px;
}
.bg-glow {
    position: fixed; inset: 0; z-index: 0; pointer-events: none;
    background:
        radial-gradient(ellipse 600px 400px at 15% 0%, rgba(232, 80, 30, 0.07) 0%, transparent 70%),
        radial-gradient(ellipse 500px 500px at 90% 85%, rgba(42, 72, 143, 0.05) 0%, transparent 70%);
}
.wrapper { position: relative; z-index: 1; }

.header {
    position: sticky; top: 0; z-index: 100;
    background: rgba(15, 23, 42, 0.88);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-subtle);
}
.header-inner {
    max-width: var(--container);
    margin: 0 auto;
    padding: 14px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}
.nav-back {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s;
}
.nav-back:hover { color: var(--accent-light); }
.nav-back:focus-visible {
    outline: 2px solid var(--accent-light);
    outline-offset: 4px;
    border-radius: 4px;
}
.header-logos {
    display: flex;
    align-items: center;
    gap: 14px;
}
.header-logos img:first-of-type { height: 34px; width: auto; display: block; }
.header-logos img:last-of-type { height: 26px; width: auto; opacity: 0.88; display: block; }
.header-divider { width: 1px; height: 22px; background: rgba(255, 255, 255, 0.12); }

.page-nav {
    max-width: var(--container);
    margin: 0 auto;
    padding: 20px 24px 0;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}
.page-nav a {
    display: inline-flex;
    align-items: center;
    padding: 9px 16px;
    background: rgba(30, 41, 59, 0.72);
    border: 1px solid var(--border-subtle);
    border-radius: 12px;
    text-decoration: none;
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 500;
    transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.page-nav a:hover {
    border-color: rgba(232, 80, 30, 0.35);
    color: var(--text);
    background: rgba(30, 41, 59, 0.92);
}
.page-nav a.active {
    background: rgba(232, 80, 30, 0.2);
    color: var(--accent-light);
    border-color: rgba(232, 80, 30, 0.45);
}
.page-nav a:focus-visible {
    outline: 2px solid var(--accent-light);
    outline-offset: 2px;
}

.container { max-width: var(--container); margin: 0 auto; padding: 24px 24px 80px; }
.article {
    background: var(--bg-card);
    border: 1px solid var(--border-subtle);
    border-radius: 16px;
    padding: 48px;
    margin-top: 20px;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.2);
    animation: fadeUp 0.6s ease-out;
}
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
@media (max-width: 640px) { .article { padding: 24px 18px; } }

.article h1 {
    font-size: clamp(1.35rem, 3vw, 1.85rem);
    font-weight: 800;
    margin-bottom: 8px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--accent);
    color: var(--text);
    letter-spacing: -0.02em;
}
.article h2 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text);
    margin-top: 40px;
    margin-bottom: 16px;
    padding-top: 28px;
    border-top: 1px solid var(--border-subtle);
    scroll-margin-top: 5rem;
}
.article h2:first-of-type { border-top: none; padding-top: 0; }
.article h3 { font-size: 1.05rem; font-weight: 600; color: var(--accent-light); margin-top: 28px; margin-bottom: 12px; }

.article p { margin-bottom: 14px; font-size: 15px; color: rgba(248, 250, 252, 0.92); }
.article ul, .article ol { margin-bottom: 14px; padding-left: 24px; }
.article li { margin-bottom: 6px; font-size: 15px; }
.article li::marker { color: var(--accent); }

.article a { color: var(--accent-light); text-decoration: none; border-bottom: 1px solid rgba(255, 107, 58, 0.35); transition: border-color 0.2s, color 0.2s; }
.article a:hover { border-bottom-color: var(--accent-light); color: #fff; }
.article a:focus-visible {
    outline: 2px solid var(--accent-light);
    outline-offset: 2px;
    border-radius: 2px;
}
.article strong { font-weight: 600; color: #fff; }

.article blockquote {
    background: rgba(232, 80, 30, 0.08);
    border-left: 3px solid var(--accent);
    padding: 14px 20px;
    margin: 16px 0;
    border-radius: 0 12px 12px 0;
    font-size: 14px;
    color: var(--text-muted);
}
.article blockquote p { margin-bottom: 0.65em; }
.article blockquote p:last-child { margin-bottom: 0; }
.article blockquote a { color: var(--accent-light); }

.article table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 14px; }
.article th { background: rgba(232, 80, 30, 0.18); color: var(--text); padding: 10px 14px; text-align: left; font-weight: 600; }
.article td { padding: 10px 14px; border-bottom: 1px solid var(--border-subtle); }
.article tr:hover td { background: rgba(255, 255, 255, 0.03); }
.article hr { border: none; border-top: 1px solid var(--border-subtle); margin: 32px 0; }
.article code { background: rgba(255, 255, 255, 0.08); padding: 2px 6px; border-radius: 4px; font-size: 13px; }

.footer { padding: 32px 24px 48px; }
.footer-inner {
    max-width: var(--container);
    margin: 0 auto;
    text-align: center;
    font-size: 0.82rem;
    color: var(--text-muted);
    opacity: 0.5;
    transition: opacity 0.35s ease;
}
.footer-inner:hover { opacity: 1; }
.footer-inner a { color: var(--accent); text-decoration: none; }
.footer-inner a:hover { text-decoration: underline; }
.footer-inner a:focus-visible {
    outline: 2px solid var(--accent-light);
    outline-offset: 3px;
    border-radius: 2px;
}

@media (max-width: 640px) {
    .header-inner { flex-direction: column; align-items: flex-start; }
    .header-logos { width: 100%; justify-content: flex-end; }
    .article { overflow-x: auto; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .article { animation: none; }
}
