/* ==========================================================================
   AIRACIO SYSTEMS DESIGN SYSTEM — CORE STYLES (systems-core.css)
   Централизованные общие стили для аналитического кластера "Анатомия Систем"
   ========================================================================== */

/* 1. ШРИФТЫ */
@import url('https://fonts.googleapis.com/css2?family=Unbounded:wght@300;400;700;900&family=JetBrains+Mono:wght@400;600;700&family=Literata:ital,wght@0,300;0,400;0,600;0,700;1,300;1,400&family=Inter:wght@300;400;500;600;700;800&display=swap');

/* 2. БАЗОВЫЕ ПРАВИЛА И СКРОЛЛ */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

/* Кастомный тонкий скроллбар */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.2);
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(139, 92, 246, 0.4);
}

/* 3. ТИПОГРАФИЧЕСКИЕ КЛАССЫ */
.font-display {
    font-family: var(--font-display, 'Unbounded', sans-serif);
}

.font-serif {
    font-family: var(--font-serif, 'Literata', Georgia, serif);
}

.font-sans {
    font-family: var(--font-sans, 'Inter', system-ui, sans-serif);
}

.font-mono {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
}

/* 4. ОПТИМИЗИРОВАННЫЙ ТЕКСТ ДЛЯ ЧТЕНИЯ */
.readable-text {
    font-family: var(--font-sans, 'Inter', system-ui, sans-serif);
    font-size: 17.5px;
    font-weight: 400;
    line-height: 1.85;
    color: var(--pale);
    max-width: 760px;
    margin-bottom: 24px;
    letter-spacing: -0.01em;
}

.readable-text strong {
    color: var(--bright);
    font-weight: 600;
}

/* 5. ИНТЕРАКТИВНЫЙ ТЕРМИН С ТУЛТИПОМ */
.term {
    border-bottom: 1px dotted var(--accent);
    color: var(--bright);
    cursor: help;
    position: relative;
    font-weight: 600;
    display: inline-block;
}

.term::after {
    content: attr(data-def);
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    background: var(--surface);
    border: 1px solid var(--accent);
    color: var(--pale);
    padding: 12px 18px;
    border-radius: 8px;
    font-size: 13.5px;
    line-height: 1.5;
    width: 290px;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.5);
    z-index: 100;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    font-family: var(--font-sans, 'Inter', sans-serif);
    font-weight: 400;
    text-transform: none;
    letter-spacing: normal;
}

.term:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

/* 6. АКАДЕМИЧЕСКИЕ СНОСКИ */
.cite {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 11px;
    color: var(--accent);
    vertical-align: super;
    margin-left: 2px;
    cursor: pointer;
    font-weight: 700;
    text-decoration: none;
    transition: color 0.2s ease;
}

.cite:hover {
    color: var(--sigma, #ff476d);
}

/* 7. ИНТЕРАКТИВНЫЕ ХЕШТЕГИ */
.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 36px 40px;
    border-top: 1px solid var(--line, rgba(255, 255, 255, 0.08));
    align-items: center;
}

.tags-title {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 11px;
    font-weight: 700;
    color: var(--cold, #94a3b8);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    margin-right: 8px;
}

.tag {
    font-family: var(--font-mono, 'JetBrains Mono', monospace);
    font-size: 11px;
    color: var(--cold, #94a3b8);
    border: 1px solid var(--line, rgba(255, 255, 255, 0.12));
    background: rgba(255, 255, 255, 0.02);
    padding: 6px 14px;
    border-radius: 6px;
    letter-spacing: 0.05em;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    user-select: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.tag:hover {
    border-color: var(--accent);
    color: #ffffff;
    background: rgba(139, 92, 246, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(139, 92, 246, 0.25);
}

.tag.active {
    border-color: var(--accent);
    background: var(--accent);
    color: #ffffff;
}

