:root {
    /* Основные цвета (дефолт — фирменный StackBridge #204f9e) */
    --color-primary: #204f9e;
    --color-primary-hover: #1a4080;
    --color-secondary: #284f9e;
    --color-success: #22c55e;
    --color-danger: #ef4444;
    --color-warning: #f59e0b;
    --color-info: #4299e1;

    /* Фон */
    --bg-primary: #f8fafc;
    --bg-secondary: #ffffff;
    --bg-tertiary: #f1f5f9;
    --bg-hover: #e2e8f0;

    /* Текст */
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;

    /* Границы */
    --border-color: #e2e8f0;

    /* Тени */
    --shadow-md: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-xl: 0 10px 24px rgba(32, 79, 158, 0.12);

    /* Персональные настройки оформления, совместимые с cources/example */
    --user-font-size: 16px;
    --user-font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --user-letter-spacing: 0px;
    --bg-pattern: none;
    --bg-tint: transparent;

    /* Акцентные градиенты и свечения (зависят от --color-primary / --color-secondary) */
    --accent-gradient: linear-gradient(
        135deg,
        var(--color-primary) 0%,
        color-mix(in srgb, var(--color-primary) 62%, var(--color-secondary)) 48%,
        var(--color-secondary) 100%
    );
    --accent-shadow: color-mix(in srgb, var(--color-primary) 32%, transparent);
    --accent-shadow-soft: color-mix(in srgb, var(--color-primary) 18%, transparent);
    --accent-shadow-light: color-mix(in srgb, var(--color-primary) 12%, transparent);
    --accent-icon-bg: linear-gradient(
        135deg,
        color-mix(in srgb, var(--color-primary) 15%, transparent),
        color-mix(in srgb, var(--color-secondary) 15%, transparent)
    );

    /* Прозрачные блоки шапки и цвет текста (пересчитывается в ui-settings.js) */
    --header-fg: rgba(255, 255, 255, 0.92);
    --header-fg-strong: #ffffff;
    --header-fg-muted: rgba(255, 255, 255, 0.72);
    --header-glass-bg: rgba(255, 255, 255, 0.12);
    --header-glass-border: rgba(255, 255, 255, 0.22);
    --header-glass-hover: rgba(255, 255, 255, 0.18);
    --header-active-bg: rgba(255, 255, 255, 0.95);
    --header-active-fg: var(--color-primary);
    --header-avatar-bg: rgba(255, 255, 255, 0.2);
    --header-avatar-border: rgba(255, 255, 255, 0.35);
    --header-avatar-fg: #ffffff;

    /* Вкладка «Курс по ИИ» в шапке */
    --nav-ai-learning: #0d9488;
    --nav-ai-learning-hover: #0f766e;
    --nav-ai-learning-bg: rgba(13, 148, 136, 0.12);
}

html.dark,
[data-theme="dark"] {
    --color-primary: #6b9ae8;
    --color-primary-hover: #8bb0ef;
    --color-secondary: #5b8fd4;
    --color-success: #4ade80;
    --color-danger: #ef4444;
    --color-warning: #fbbf24;
    --color-info: #3b82f6;

    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;
    --bg-hover: #475569;

    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;

    --border-color: #334155;

    --shadow-md: 0 2px 4px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 4px 12px rgba(0, 0, 0, 0.4);

    --nav-ai-learning: #2dd4bf;
    --nav-ai-learning-hover: #5eead4;
    --nav-ai-learning-bg: rgba(45, 212, 191, 0.15);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: var(--user-font-size);
    position: relative;
    min-height: 100%;
    background-color: var(--bg-primary);
    background-image: var(--bg-pattern, none);
    background-repeat: repeat;
}

/* Оттенок на всю высоту документа (не только viewport). */
html::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--bg-tint, transparent);
    pointer-events: none;
    z-index: 0;
}

body {
    position: relative;
    z-index: 1;
    font-family: var(--user-font-family);
    font-size: 1rem;
    letter-spacing: var(--user-letter-spacing);
    background: transparent;
    color: var(--text-primary);
    line-height: 1.8;
    min-height: 100%;
    transition: color 0.3s ease;
}

html.theme-transition *,
html.theme-transition *::before,
html.theme-transition *::after {
    transition: background-color 0.25s ease, border-color 0.25s ease, color 0.25s ease, box-shadow 0.25s ease;
}

.layout-settings-btn {
    width: 40px;
    height: 40px;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 18px;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.layout-settings-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
    border-color: var(--color-primary);
}

.layout-settings-btn:active {
    transform: scale(0.96);
}

.notification-bell-btn {
    position: relative;
}

.notification-bell-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--color-danger, #e53e3e);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    pointer-events: none;
}

.notification-center-panel {
    position: fixed;
    z-index: 10062;
    width: min(400px, calc(100vw - 24px));
    max-height: min(70vh, 520px);
    display: flex;
    flex-direction: column;
    background: var(--bg-primary, #fff);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 14px;
    box-shadow: var(--shadow-lg, 0 18px 44px rgba(15, 23, 42, 0.16));
    overflow: hidden;
    opacity: 0;
    transform: translateY(-8px) scale(0.98);
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.notification-center-panel.is-open {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.notification-center-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-color, #e2e8f0);
    background: var(--bg-secondary, #f8fafc);
}

.notification-center-title {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary, #1a202c);
}

.notification-center-close {
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: var(--text-secondary, #718096);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

.notification-center-close:hover {
    background: var(--bg-hover, #edf2f7);
    color: var(--text-primary, #1a202c);
}

.notification-center-list {
    overflow-y: auto;
    padding: 8px;
    flex: 1;
}

.notification-center-empty {
    padding: 28px 16px;
    text-align: center;
    color: var(--text-secondary, #718096);
    font-size: 14px;
}

.notification-center-item {
    display: flex;
    align-items: stretch;
    gap: 0;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 12px;
    margin-bottom: 8px;
    overflow: hidden;
    background: var(--bg-primary, #fff);
}

.notification-center-item-main {
    flex: 1;
    padding: 12px 14px;
    border: 0;
    background: transparent;
    text-align: left;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 4px;
    color: var(--text-primary, #1a202c);
}

.notification-center-item-main:hover {
    background: var(--bg-hover, #f7fafc);
}

.notification-center-item-title {
    font-weight: 700;
    font-size: 14px;
}

.notification-center-item-text {
    font-size: 12px;
    line-height: 1.4;
    color: var(--text-secondary, #718096);
}

.notification-center-item-dismiss {
    width: 40px;
    border: 0;
    border-left: 1px solid var(--border-color, #e2e8f0);
    background: var(--bg-secondary, #f8fafc);
    color: var(--text-secondary, #718096);
    font-size: 18px;
    cursor: pointer;
}

.notification-center-item-dismiss:hover {
    background: var(--bg-hover, #edf2f7);
    color: var(--color-danger, #e53e3e);
}

.notification-center-footer {
    padding: 12px 16px;
    border-top: 1px solid var(--border-color, #e2e8f0);
    background: var(--bg-secondary, #f8fafc);
}

.notification-center-dismiss-all {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 10px;
    background: var(--bg-primary, #fff);
    color: var(--text-primary, #1a202c);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.notification-center-dismiss-all:hover {
    border-color: var(--color-danger, #e53e3e);
    color: var(--color-danger, #e53e3e);
}

.notification-center-confirm {
    display: none;
    flex-direction: column;
    gap: 10px;
}

.notification-center-confirm.is-visible {
    display: flex;
}

.notification-center-confirm-text {
    margin: 0;
    font-size: 13px;
    line-height: 1.45;
    color: var(--text-secondary, #718096);
}

.notification-center-confirm-actions {
    display: flex;
    gap: 8px;
}

.notification-center-confirm-actions button {
    flex: 1;
    padding: 9px 12px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.notification-center-confirm-yes {
    border: 0;
    background: var(--color-danger, #e53e3e);
    color: #fff;
}

.notification-center-confirm-no {
    border: 1px solid var(--border-color, #e2e8f0);
    background: var(--bg-primary, #fff);
    color: var(--text-primary, #1a202c);
}

.notification-unread-hint {
    position: fixed;
    top: 72px;
    right: 20px;
    z-index: 10061;
    padding: 14px 22px;
    border-radius: 12px;
    background: linear-gradient(135deg, #38bdf8 0%, #0ea5e9 100%);
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: 0.01em;
    box-shadow: 0 10px 28px rgba(14, 165, 233, 0.38), 0 2px 8px rgba(0, 0, 0, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.28);
    animation: slideIn 0.3s ease;
    max-width: 380px;
}

.header .notification-bell-btn {
    background: var(--header-glass-bg);
    border-color: var(--header-glass-border);
    color: var(--header-fg-strong);
}

.header .notification-bell-btn:hover {
    background: var(--header-glass-hover);
    color: var(--header-fg-strong);
    border-color: var(--header-glass-border);
}

/* Настройки оформления: общий UI платформы, совместимый с cources/example. */
.settings-overlay {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    justify-content: flex-end;
    background: rgba(15, 23, 42, 0.45);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.settings-overlay.settings-visible {
    opacity: 1;
    pointer-events: auto;
}

.settings-panel {
    width: min(460px, calc(100vw - 24px));
    height: 100%;
    overflow-y: auto;
    background: var(--bg-secondary);
    border-left: 1px solid var(--border-color);
    box-shadow: -18px 0 48px rgba(15, 23, 42, 0.18);
    transform: translateX(100%);
    transition: transform 0.22s ease;
}

.settings-visible .settings-panel {
    transform: translateX(0);
}

.settings-header {
    position: sticky;
    top: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
}

.settings-title {
    font-size: 18px;
    font-weight: 700;
}

.settings-close {
    width: 36px;
    height: 36px;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 24px;
    line-height: 1;
}

.settings-close:hover {
    color: var(--text-primary);
    border-color: var(--color-primary);
}

.settings-section {
    padding: 22px 24px;
    border-bottom: 1px solid var(--border-color);
}

.settings-section-title {
    margin-bottom: 14px;
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.settings-option-grid-3,
.settings-option-grid-fonts,
.settings-option-grid-tints,
.settings-option-grid-patterns,
.settings-option-grid-accents {
    display: grid;
    gap: 12px;
}

.settings-option-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.settings-option-grid-fonts,
.settings-option-grid-tints,
.settings-option-grid-patterns,
.settings-option-grid-accents {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.settings-option-card,
.font-card,
.tint-card,
.pattern-card,
.accent-card {
    border: 1px solid var(--border-color);
    border-radius: 14px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    cursor: pointer;
    text-align: left;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.settings-option-card:hover,
.font-card:hover,
.tint-card:hover,
.pattern-card:hover,
.accent-card:hover {
    border-color: var(--color-primary);
    box-shadow: var(--shadow-xl);
    transform: translateY(-1px);
}

.settings-option-card.selected,
.font-card.selected,
.tint-card.selected,
.pattern-card.selected,
.accent-card.selected {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.18), var(--shadow-md);
}

.settings-option-card {
    padding: 10px;
}

.settings-option-label,
.font-card-name,
.tint-card-label,
.pattern-card-label,
.accent-card-label {
    display: block;
    margin-top: 8px;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
    color: var(--text-secondary);
}

.theme-preview {
    display: grid;
    gap: 6px;
    height: 70px;
    padding: 10px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
}

.theme-preview span {
    display: block;
    border-radius: 5px;
}

.theme-preview-system {
    grid-template-columns: repeat(2, 1fr);
    background: linear-gradient(90deg, #f8fafc 0 50%, #0f172a 50% 100%);
}

.theme-preview-light {
    background: #f8fafc;
}

.theme-preview-dark {
    background: #0f172a;
}

.theme-preview-system span,
.theme-preview-light span {
    background: #94a3b8;
}

.theme-preview-dark span {
    background: #64748b;
}

.settings-slider-row {
    display: grid;
    grid-template-columns: auto 1fr auto auto;
    align-items: center;
    gap: 12px;
}

.settings-slider {
    width: 100%;
    accent-color: var(--color-primary);
}

.settings-slider-edge {
    color: var(--text-muted);
    font-weight: 700;
}

.settings-slider-edge--small {
    font-size: 12px;
}

.settings-slider-edge--wide {
    letter-spacing: 2px;
}

.settings-slider-value {
    min-width: 48px;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
    text-align: right;
}

.font-preview-area {
    margin-top: 16px;
    padding: 16px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--bg-tertiary);
}

.font-preview-area h2 {
    margin: 0 0 8px;
    font-size: 1.1em;
}

.font-preview-area p {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.75;
}

.font-card,
.tint-card,
.pattern-card,
.accent-card {
    padding: 12px;
}

.font-card-sample {
    display: block;
    font-size: 24px;
    font-weight: 700;
    text-align: center;
}

.tint-card-swatch,
.pattern-card-preview,
.accent-card-swatch {
    display: block;
    height: 58px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
}

.settings-footer {
    padding: 20px 24px 28px;
}

.settings-reset-btn {
    width: 100%;
    padding: 12px 18px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    cursor: pointer;
    font-weight: 600;
}

.settings-reset-btn:hover {
    color: var(--text-primary);
    border-color: var(--color-primary);
}

@media (max-width: 768px) {
    .settings-overlay {
        align-items: flex-end;
        justify-content: stretch;
    }

    .settings-panel {
        width: 100%;
        max-height: min(92dvh, 760px);
        height: auto;
        border-left: 0;
        border-top: 1px solid var(--border-color);
        border-radius: 20px 20px 0 0;
        transform: translateY(calc(100% + 12px));
        touch-action: pan-y;
        padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    }

    .settings-visible .settings-panel {
        transform: translateY(0);
    }

    .settings-panel.is-dragging {
        transition: none;
    }

    .settings-sheet-handle-wrap {
        display: flex;
        justify-content: center;
        padding: 10px 0 4px;
        cursor: grab;
        touch-action: none;
    }

    .settings-sheet-handle {
        width: 42px;
        height: 5px;
        border-radius: 999px;
        background: color-mix(in srgb, var(--text-muted) 55%, transparent);
    }

    .settings-option-grid-3,
    .settings-option-grid-fonts,
    .settings-option-grid-tints,
    .settings-option-grid-patterns,
    .settings-option-grid-accents {
        grid-template-columns: 1fr;
    }
}

.settings-sheet-handle-wrap {
    display: none;
}

img {
    display: block;
    margin-inline: auto;
    width: 90%;
    max-width: 100%;
}

/* Header */
.header {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-md);
}

.logo {
    font-size: 20px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    padding: 8px 16px;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.user-menu:hover {
    background: var(--bg-tertiary);
}

.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 600;
    color: white;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px;
}

/* Широкий layout для страниц HR (таблицы студентов, менторов) */
.container.hr-portal-wide {
    max-width: min(1920px, calc(100vw - 32px));
    width: 100%;
    box-sizing: border-box;
}

.topic-container {
    max-width: 900px;
}

/* Welcome Section */
.welcome-section {
    margin-bottom: 40px;
}

.welcome-section h1 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 10px;
}

.subtitle {
    font-size: 18px;
    color: var(--text-secondary);
}

/* Loading State */
.loading-state {
    text-align: center;
    padding: 60px 20px;
}

.spinner {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    border: 4px solid var(--bg-tertiary);
    border-top: 4px solid var(--color-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.spinner-small {
    width: 30px;
    height: 30px;
    margin: 0 auto 10px;
    border: 3px solid var(--bg-tertiary);
    border-top: 3px solid var(--color-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-state p {
    color: var(--text-muted);
}

/* Error State */
.error-state {
    text-align: center;
    padding: 60px 20px;
    background: var(--bg-secondary);
    border-radius: 16px;
    box-shadow: var(--shadow-md);
}

.error-icon {
    font-size: 64px;
    margin-bottom: 20px;
}

.error-state h3 {
    font-size: 24px;
    color: var(--color-danger);
    margin-bottom: 10px;
}

.error-state p {
    color: var(--text-secondary);
    margin-bottom: 20px;
}

/* Directions Grid */
.directions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

.directions-grid .direction-card {
    background: var(--bg-secondary);
    border-radius: 16px;
    padding: 24px;
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
}

.directions-grid .direction-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--color-primary);
}

/* Информационный блок без назначенного направления — не кнопка */
.directions-grid .direction-card--empty {
    cursor: default;
}
.directions-grid .direction-card--empty:hover {
    transform: none;
    box-shadow: var(--shadow-md);
    border-color: transparent;
}

.direction-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.direction-info h3 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
}

.direction-description {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 20px;
}

.direction-progress {
    display: flex;
    align-items: center;
    gap: 12px;
}

.progress-bar {
    flex: 1;
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.progress-text {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    min-width: 45px;
}

/* Layout */
.layout {
    display: flex;
    min-height: calc(100vh - 80px);
}

.sidebar {
    width: 320px;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-color);
    padding: 30px;
    overflow-y: auto;
}

.course-header {
    margin-bottom: 30px;
}

.course-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.course-progress {
    margin-bottom: 20px;
}

.progress-label {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
}

/* Topics List */
.topics-list {
    list-style: none;
}

.topic-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 8px;
    transition: background 0.2s ease;
    cursor: pointer;
}

.topic-item:hover {
    background: var(--bg-hover);
}

.topic-item.active {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
}

.topic-item.completed {
    opacity: 0.65;
    filter: grayscale(20%);
}

.topic-item.completed:hover {
    opacity: 0.85;
    filter: grayscale(0%);
}

.topic-item.completed .topic-title {
    color: var(--text-muted);
    text-decoration: line-through;
    text-decoration-thickness: 1px;
}

.topic-item.completed .topic-duration {
    color: var(--text-muted);
}

.topic-status {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    flex-shrink: 0;
}

.topic-item.completed .topic-status {
    background: var(--color-success);
    color: white;
    font-size: 16px;
}

.topic-item.active .topic-status {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    color: white;
}

.topic-item:not(.completed):not(.active) .topic-status {
    background: var(--bg-tertiary);
    color: var(--text-muted);
}

.topic-info {
    flex: 1;
}

.topic-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 4px;
}

.topic-duration {
    font-size: 12px;
    color: var(--text-muted);
}

/* Content */
.content {
    flex: 1;
    padding: 40px;
    overflow-y: auto;
}

.back-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    text-decoration: none;
    margin-bottom: 30px;
    font-weight: 500;
    transition: color 0.3s ease;
}

.back-button:hover {
    color: var(--color-primary);
}

.welcome-card {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    color: white;
    padding: 30px;
    border-radius: 16px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-md);
}

.welcome-card h2 {
    font-size: 28px;
    margin-bottom: 10px;
}

.welcome-card p {
    font-size: 16px;
    opacity: 0.95;
    line-height: 1.8;
}

.btn-start {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    color: white;
    border: none;
    padding: 16px 32px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-md);
}

.btn-start:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Topic Page */
.topic-header {
    margin-bottom: 40px;
}

.topic-header .topic-title {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 10px;
}

.topic-meta {
    display: flex;
    align-items: center;
    gap: 20px;
    color: var(--text-muted);
    font-size: 14px;
}

.content-section {
    background: var(--bg-secondary);
    padding: 30px;
    border-radius: 16px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-md);
}

.content-section h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
}

.content-section h3 {
    font-size: 20px;
    font-weight: 600;
    margin-top: 24px;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.content-section p {
    margin-bottom: 16px;
    color: var(--text-secondary);
}

.content-section ul, .content-section ol {
    margin-left: 24px;
    margin-bottom: 16px;
}

.content-section li {
    margin-bottom: 8px;
    color: var(--text-secondary);
}

.practice-task {
    background: var(--bg-tertiary);
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    border-left: 4px solid var(--color-warning);
}

.practice-task h3 {
    margin-top: 0;
    color: var(--color-warning);
}

.ai-interview {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    border: 2px solid var(--color-primary);
}

.ai-interview h2 {
    color: var(--color-primary);
}

/* Buttons */
.btn {
    padding: 14px 28px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.btn-secondary:hover {
    background: var(--bg-hover);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.actions {
    display: flex;
    gap: 16px;
    margin-top: 40px;
    flex-wrap: wrap;
}

/* Theme Toggle */
.theme-toggle {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    transition: all 0.3s ease;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-toggle:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: var(--shadow-lg);
}

/* Header Enhancements */

/* Главная: чуть больше воздуха в шапке с табами */
.header.header--home {
    padding: 14px 32px;
}

@media (max-width: 900px) {
    .header.header--home {
        padding: 14px 16px;
    }
}

.header-left {
    display: flex;
    align-items: center;
    gap: 32px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.header-shell {
    width: 100%;
}

.header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    min-width: 0;
}

.header-top > .nav-menu {
    flex: 1 1 auto;
    min-width: 0;
}

.header-top > .logo {
    flex-shrink: 0;
}

.header-tool-btn {
    box-sizing: border-box;
    width: 40px;
    height: 40px;
    padding: 0;
    margin: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.15s ease;
    flex-shrink: 0;
    font: inherit;
}

.header-tool-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
    border-color: var(--color-primary);
}

.header-tool-btn:active {
    transform: scale(0.96);
}

.user-menu-btn {
    gap: 0;
    border: none;
    background: transparent;
}

.user-menu-btn .user-info {
    display: none;
}

.user-menu-btn .user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    font-size: 13px;
}

.layout-settings-btn.header-tool-btn {
    width: 40px;
    height: 40px;
    padding: 0;
    font-size: 18px;
}

/* ФИО в шапке — только на широких экранах, иначе съедает место вкладок (EDU-530) */
@media (min-width: 1200px) {
    .user-menu-btn {
        width: auto;
        padding: 0;
        gap: 10px;
    }

    .user-menu-btn .user-info {
        display: flex;
    }

    .user-menu-btn .user-avatar {
        width: 40px;
        height: 40px;
        border-radius: 50%;
    }
}

.logo {
    font-size: 20px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    cursor: pointer;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-item {
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-item:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

.nav-item.active {
    background: var(--bg-tertiary);
    color: var(--color-primary);
    font-weight: 600;
}

.nav-item.nav-item--ai-learning {
    color: var(--nav-ai-learning);
    font-weight: 600;
}

.nav-item.nav-item--ai-learning:hover {
    background: var(--nav-ai-learning-bg);
    color: var(--nav-ai-learning-hover);
}

.nav-item.nav-item--ai-learning.nav-item--ai-learning-active {
    background: var(--nav-ai-learning-bg);
    color: var(--nav-ai-learning-hover);
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 600;
    color: white;
}

.user-avatar-header {
    width: 36px;
    height: 36px;
    font-size: 14px;
}

.user-info {
    display: flex;
    flex-direction: column;
}

.user-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.user-role {
    font-size: 12px;
    color: var(--text-muted);
}

.user-group {
    margin-top: 2px;
    display: inline-block;
    padding: 2px 8px;
    font-size: 11px;
    line-height: 1.4;
    color: var(--text-primary);
    background: var(--bg-subtle, rgba(102, 126, 234, 0.12));
    border-radius: 999px;
    letter-spacing: 0.2px;
}

/* Page Layout */
.page-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 8px;
}

.page-subtitle {
    color: var(--text-muted);
    font-size: 16px;
    margin-bottom: 40px;
}

/* Direction Card (Dashboard version) */
.direction-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 32px;
    margin-bottom: 32px;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-md);
}

.direction-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--color-primary);
}

.direction-card.clickable {
    cursor: pointer;
}

.direction-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.direction-icon {
    width: 64px;
    height: 64px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
}

.direction-info h2 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 4px;
}

.direction-subtitle {
    color: var(--text-muted);
    font-size: 14px;
}

.direction-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 24px;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.direction-stats .stat-label {
    color: var(--text-muted);
    font-size: 13px;
    margin-bottom: 4px;
}

.direction-stats .stat-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--color-primary);
}

.progress-section {
    margin-bottom: 24px;
}

.progress-label {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 14px;
}

.progress-bar {
    height: 12px;
    background: var(--bg-tertiary);
    border-radius: 6px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    transition: width 0.3s ease;
}

.btn-continue {
    width: 100%;
    height: 48px;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-continue:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(124, 58, 237, 0.4);
}

a.btn-continue {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    box-sizing: border-box;
}

.direction-card.direction-card--ai-learning {
    max-width: 640px;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    cursor: default;
    text-align: center;
}

.direction-card--ai-learning .direction-header {
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.direction-card--ai-learning .direction-info {
    text-align: center;
    max-width: 36rem;
    margin: 0 auto;
}

.direction-card--ai-learning .progress-label {
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 16px;
}

.direction-card--ai-learning .progress-bar {
    max-width: 320px;
    margin: 0 auto;
}

.direction-card.direction-card--ai-learning:hover {
    border-color: var(--nav-ai-learning);
    box-shadow: var(--shadow-lg);
}

.direction-card--ai-learning .direction-icon {
    background: linear-gradient(135deg, var(--nav-ai-learning) 0%, var(--nav-ai-learning-hover) 100%);
}

.direction-card--ai-learning .progress-fill--ai {
    background: linear-gradient(90deg, var(--nav-ai-learning) 0%, var(--nav-ai-learning-hover) 100%);
}

.direction-card--ai-learning .btn-continue {
    background: linear-gradient(135deg, var(--nav-ai-learning) 0%, var(--nav-ai-learning-hover) 100%);
}

.direction-card--ai-learning .btn-continue:hover {
    box-shadow: 0 10px 30px rgba(13, 148, 136, 0.35);
}

.ai-learning-hub-wrap {
    margin-top: 8px;
    display: flex;
    justify-content: center;
    width: 100%;
}

.ai-learning-hub-page .page-title,
.ai-learning-hub-page .page-subtitle {
    text-align: center;
}

.ai-learning-hub-page .page-subtitle {
    max-width: 36rem;
    margin-left: auto;
    margin-right: auto;
}

/* Stats Grid (legacy, для других страниц) */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.stat-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    box-shadow: var(--shadow-md);
}

.stat-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.stat-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    background: var(--bg-tertiary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.stat-card-title {
    font-size: 14px;
    color: var(--text-muted);
}

.stat-card-value {
    font-size: 32px;
    font-weight: 700;
    color: var(--text-primary);
}

.stats-grid .stat-value {
    font-size: 32px;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 8px;
}

.stats-grid .stat-label {
    font-size: 14px;
    color: var(--text-secondary);
}

/* Статистика по топикам (главная студента) */
.topics-stats-section {
    margin-bottom: 40px;
}

.topics-stats-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 20px 0;
    letter-spacing: 0.02em;
}

.topics-stats-block {
    display: flex;
    align-items: center;
    gap: 32px;
    padding: 28px 32px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    box-shadow: var(--shadow-md);
    flex-wrap: wrap;
}

/* Круговая диаграмма (donut) */
.topics-chart-wrap {
    position: relative;
    width: 140px;
    height: 140px;
    flex-shrink: 0;
}

.topics-chart-donut {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: conic-gradient(#e5e7eb 0deg 360deg);
    transition: background 0.5s ease;
}

.topics-chart-center {
    position: absolute;
    inset: 14px;
    border-radius: 50%;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.topics-chart-percent {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

/* Легенда справа от диаграммы */
.topics-stats-legend {
    display: flex;
    flex-direction: column;
    gap: 20px;
    min-width: 200px;
}

.topics-legend-item {
    display: flex;
    align-items: center;
    gap: 14px;
}

.topics-legend-dot {
    width: 14px;
    height: 14px;
    border-radius: 4px;
    flex-shrink: 0;
}

.topics-legend-item--completed .topics-legend-dot {
    background: #16a34a;
}

.topics-legend-item--remaining .topics-legend-dot {
    background: var(--color-primary);
}

.topics-legend-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.topics-legend-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.topics-legend-label {
    font-size: 0.9375rem;
    color: var(--text-muted);
}

/* Profile Page */
.profile-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 32px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-md);
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--border-color);
}

.profile-avatar {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
}

.profile-info h2 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 8px;
}

.role-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(124, 58, 237, 0.2);
    border: 1px solid var(--color-primary);
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    color: var(--color-primary);
}

.info-section {
    margin-bottom: 32px;
}

.info-section h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.info-row {
    display: flex;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    width: 180px;
    color: var(--text-muted);
    font-size: 14px;
    flex-shrink: 0;
}

.info-value {
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 500;
}

.btn-danger {
    background: transparent;
    border: 2px solid var(--color-danger);
    color: var(--color-danger);
    width: 100%;
    height: 48px;
}

.btn-danger:hover {
    background: var(--color-danger);
    color: white;
}

/* Placeholder Pages */
.placeholder-body {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.placeholder-container {
    max-width: 600px;
    width: 100%;
    background: var(--bg-secondary);
    border-radius: 16px;
    padding: 48px;
    box-shadow: var(--shadow-lg);
    text-align: center;
}

.icon {
    font-size: 80px;
    margin-bottom: 24px;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

.placeholder-container h1 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 16px;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.placeholder-container p {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 32px;
}

.features {
    text-align: left;
    margin-bottom: 32px;
    padding: 24px;
    background: var(--bg-primary);
    border-radius: 12px;
}

.features h3 {
    font-size: 18px;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.features ul {
    list-style: none;
}

.features li {
    padding: 8px 0;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 12px;
}

.features li::before {
    content: "\f00c";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: var(--color-primary);
    color: white;
    border-radius: 50%;
    font-weight: bold;
    flex-shrink: 0;
}

.status {
    display: inline-block;
    padding: 8px 16px;
    background: rgba(237, 137, 54, 0.2);
    color: #ed8936;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 24px;
}

/* Responsive */
@media (max-width: 768px) {
    .header.header--home {
        padding: 10px 12px calc(10px + env(safe-area-inset-top, 0px));
    }

    .header-top {
        gap: 8px;
    }

    .header .logo {
        font-size: 15px;
        line-height: 1.25;
        flex: 0 0 auto;
        min-width: 0;
        max-width: none;
    }

    .header .logo-text {
        display: none;
    }

    .header-actions {
        gap: 6px;
    }

    .header-tool-btn,
    .layout-settings-btn.header-tool-btn {
        width: 38px;
        height: 38px;
        border-radius: 11px;
    }

    .user-menu-btn.header-tool-btn {
        width: auto;
        height: auto;
        padding: 0;
        border: none;
        background: transparent;
        border-radius: 0;
    }

    .user-menu-btn .user-avatar {
        width: 36px;
        height: 36px;
        font-size: 12px;
    }

    .nav-menu:not(.nav-menu--drawer) {
        display: none !important;
    }

    .nav-menu.nav-menu--drawer {
        display: flex !important;
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        position: fixed;
        top: 8px;
        right: 8px;
        width: min(360px, calc(100vw - 16px));
        height: calc(100dvh - 16px);
        margin: 0;
        padding: calc(18px + env(safe-area-inset-top, 0px)) 14px calc(18px + env(safe-area-inset-bottom, 0px));
        background:
            radial-gradient(circle at 100% 0%, color-mix(in srgb, var(--color-primary) 12%, transparent), transparent 34%),
            var(--bg-secondary);
        border-left: 1px solid var(--border-color);
        border: 1px solid color-mix(in srgb, var(--border-color) 84%, var(--color-primary));
        box-shadow: -16px 0 46px rgba(15, 23, 42, 0.22);
        z-index: 10060;
        transform: translateX(calc(100% + 16px));
        transition: transform 0.22s ease;
        overflow-y: auto;
        overflow-x: hidden;
        flex-wrap: nowrap;
        max-width: none;
        mask-image: none;
        -webkit-mask-image: none;
        border-radius: 24px;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .nav-menu.nav-menu--drawer::before {
        content: 'Разделы главной';
        display: block;
        padding: 2px 4px 6px;
        color: var(--text-muted);
        font-size: 0.72rem;
        font-weight: 800;
        letter-spacing: 0.12em;
        line-height: 1.2;
        text-transform: uppercase;
    }

    .nav-toggle:not([hidden]) {
        display: inline-flex !important;
    }

    .nav-menu.nav-menu--drawer.is-open {
        transform: translateX(0);
    }

    .nav-menu.nav-menu--drawer .nav-item {
        width: 100%;
        justify-content: flex-start;
        min-width: 0;
        padding: 13px 14px;
        font-size: 0.95rem;
        line-height: 1.25;
        background: color-mix(in srgb, var(--bg-tertiary) 82%, transparent);
        border: 1px solid color-mix(in srgb, var(--border-color) 88%, var(--color-primary));
        border-radius: 16px;
        color: var(--text-primary);
        white-space: normal;
        overflow-wrap: anywhere;
    }

    .nav-menu.nav-menu--drawer .home-tab {
        width: 100%;
        justify-content: flex-start;
        min-width: 0;
        min-height: 48px;
        padding: 13px 14px;
        font-size: 0.95rem;
        line-height: 1.25;
        background: color-mix(in srgb, var(--bg-tertiary) 82%, transparent);
        border: 1px solid color-mix(in srgb, var(--border-color) 88%, var(--color-primary));
        border-radius: 16px;
        color: var(--text-primary);
        text-align: left;
        white-space: normal;
        overflow-wrap: anywhere;
        box-shadow: 0 6px 18px rgba(15, 23, 42, 0.04);
    }

    .nav-menu.nav-menu--drawer .home-tab i,
    .nav-menu.nav-menu--drawer .nav-item i {
        width: 22px;
        min-width: 22px;
        color: var(--color-primary);
    }

    .nav-menu.nav-menu--drawer .home-tab.active {
        background:
            radial-gradient(circle at 100% 0%, rgba(255, 255, 255, 0.24), transparent 42%),
            linear-gradient(135deg, var(--color-primary), var(--color-secondary));
        color: #ffffff;
        border-color: transparent;
        box-shadow: 0 12px 26px var(--accent-shadow-soft);
    }

    .nav-menu.nav-menu--drawer .home-tab.active i {
        color: #ffffff;
    }

    .nav-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(15, 23, 42, 0.45);
        z-index: 10050;
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transition: opacity 0.22s ease, visibility 0.22s ease;
    }

    .nav-backdrop.is-active {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    body.nav-drawer-open {
        overflow: hidden;
    }

    body.nav-drawer-open .header {
        z-index: 10061;
        overflow: visible;
    }

    .layout {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }

    .content {
        padding: 20px;
    }

    .directions-grid {
        grid-template-columns: 1fr;
    }

    .direction-stats {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .topics-stats-block {
        flex-direction: column;
        align-items: flex-start;
    }

    .profile-header {
        flex-direction: column;
        text-align: center;
    }

    .info-row {
        flex-direction: column;
        gap: 4px;
    }

    .info-label {
        width: 100%;
    }

    .messenger-container {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
        max-height: 300px;
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }

    .message {
        max-width: 85%;
    }
}

/* Кнопка мобильного меню (скрыта на десктопе) */
.nav-toggle {
    display: none;
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background: var(--bg-tertiary);
    color: var(--text-primary);
    cursor: pointer;
    font-size: 18px;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.nav-toggle:hover {
    background: var(--bg-hover);
    border-color: var(--color-primary);
}

.nav-backdrop {
    display: none;
}

/* ========== MESSENGER STYLES ========== */

body.messenger-body {
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100vh;
}

.messenger-container {
    display: flex;
    flex: 1;
    max-width: 1400px;
    margin: 0 auto;
    width: 100%;
    background: var(--bg-secondary);
    overflow: hidden;
}

/* Sidebar with mentors list */
.sidebar {
    width: 320px;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-header h2 {
    font-size: 20px;
    margin-bottom: 12px;
}

.sidebar-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 4px;
}

.sidebar-subtitle {
    font-size: 13px;
    color: var(--text-muted);
}

.search-box {
    width: 100%;
    padding: 10px 16px;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    font-size: 14px;
    outline: none;
    transition: all 0.3s ease;
    background: var(--bg-primary);
    color: var(--text-primary);
}

.search-box:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.mentors-list {
    flex: 1;
    overflow-y: auto;
}

.mentor-item {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
    transition: background 0.2s ease;
    display: flex;
    align-items: center;
    gap: 12px;
}

.mentor-item:hover {
    background: var(--bg-primary);
}

.mentor-item.active {
    background: rgba(102, 126, 234, 0.1);
    border-left: 3px solid var(--color-primary);
}

.mentor-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-info) 0%, var(--color-primary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
    font-weight: 600;
    flex-shrink: 0;
    position: relative;
}

.online-indicator {
    width: 12px;
    height: 12px;
    background: var(--color-success);
    border: 2px solid white;
    border-radius: 50%;
    position: absolute;
    bottom: 0;
    right: 0;
}

.offline-indicator {
    background: var(--text-muted);
}

.mentor-info {
    flex: 1;
    min-width: 0;
}

.mentor-name {
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 4px;
}

.mentor-specialty {
    font-size: 13px;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.last-message {
    font-size: 13px;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 4px;
}

.message-time {
    font-size: 12px;
    color: var(--text-muted);
    flex-shrink: 0;
}

.unread-badge {
    width: 20px;
    height: 20px;
    background: var(--color-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 600;
    flex-shrink: 0;
}

/* Chat area */
.chat-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--bg-primary);
}

.chat-header {
    padding: 20px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 12px;
}

.chat-header-info {
    flex: 1;
}

.chat-header-name {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 4px;
}

.chat-header-status {
    font-size: 13px;
    color: var(--text-secondary);
}

.chat-actions {
    display: flex;
    gap: 8px;
}

.action-btn {
    width: 40px;
    height: 40px;
    border: none;
    background: var(--bg-primary);
    border-radius: 50%;
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.action-btn:hover {
    background: var(--border-color);
    transform: scale(1.05);
}

.messages-container {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.message {
    display: flex;
    gap: 10px;
    max-width: 70%;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message.sent {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.message-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-info) 0%, var(--color-primary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 14px;
    font-weight: 600;
    flex-shrink: 0;
}

.message-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.message-bubble {
    padding: 12px 16px;
    border-radius: 16px;
    word-wrap: break-word;
}

.message.sent .message-bubble {
    background: var(--color-primary);
    color: white;
    border-bottom-right-radius: 4px;
}

.message.received .message-bubble {
    background: var(--bg-hover);
    color: var(--text-primary);
    border-bottom-left-radius: 4px;
}

.message-meta {
    font-size: 11px;
    color: var(--text-muted);
    padding: 0 4px;
}

.message.sent .message-meta {
    text-align: right;
}

.date-separator {
    text-align: center;
    margin: 16px 0;
    position: relative;
}

.date-separator span {
    background: var(--bg-primary);
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 600;
}

.input-area {
    padding: 16px 20px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    display: flex;
    gap: 12px;
    align-items: flex-end;
}

.input-wrapper {
    flex: 1;
    position: relative;
}

.message-input {
    width: 100%;
    padding: 12px 50px 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 24px;
    font-size: 14px;
    font-family: inherit;
    outline: none;
    resize: none;
    max-height: 120px;
    transition: all 0.3s ease;
    background: var(--bg-primary);
    color: var(--text-primary);
}

.message-input:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.attach-btn {
    position: absolute;
    right: 12px;
    bottom: 12px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 20px;
    opacity: 0.6;
    transition: opacity 0.2s ease;
}

.attach-btn:hover {
    opacity: 1;
}

.send-btn {
    width: 48px;
    height: 48px;
    border: none;
    background: linear-gradient(135deg, var(--color-info) 0%, var(--color-primary) 100%);
    color: white;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.send-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.send-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.empty-state {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
}

.empty-state-icon {
    font-size: 64px;
    margin-bottom: 16px;
}

.empty-state h3 {
    font-size: 20px;
    margin-bottom: 8px;
    color: var(--text-secondary);
}

.empty-state p {
    font-size: 14px;
}

/* ========== MODULES GRID ========== */

.modules-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

.module-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-md);
    position: relative;
}

.module-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--color-primary);
}

.module-card.locked {
    opacity: 0.6;
    cursor: not-allowed;
}

.module-card.locked:hover {
    transform: none;
    box-shadow: var(--shadow-md);
}

.lock-icon {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 24px;
}

.module-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.module-info h3 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 8px;
}

.module-description {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 20px;
}

.module-progress {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* ========== TOPICS SIDEBAR ========== */

.progress-info {
    background: var(--bg-tertiary);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 24px;
}

.progress-text {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.topics-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* ========== WELCOME CARD (Topics page) ========== */

.welcome-icon {
    width: 80px;
    height: 80px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    margin-bottom: 24px;
}

.stat-box {
    background: var(--bg-tertiary);
    border-radius: 8px;
    padding: 16px;
    text-align: center;
}

.stat-box-value {
    font-size: 28px;
    font-weight: 700;
    color: var(--color-primary);
    margin-bottom: 4px;
}

.stat-box-label {
    font-size: 13px;
    color: var(--text-muted);
}

/* ========== TOPIC PAGE ========== */

.topic-description {
    font-size: 16px;
    color: var(--text-secondary);
    line-height: 1.6;
}

.meta-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 13px;
    color: var(--text-secondary);
}

.content-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 32px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-md);
}

.content-card h2 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 16px;
}

.content-card h3 {
    font-size: 20px;
    font-weight: 600;
    margin: 24px 0 12px;
    color: var(--color-primary);
}

.content-card p {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 16px;
}

.content-card ul {
    margin-left: 24px;
    margin-bottom: 16px;
}

.content-card li {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 8px;
}

.action-buttons {
    display: flex;
    gap: 16px;
    margin-top: 32px;
}

/* ========== MENTOR CONTACT ========== */

.mentor-contact {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 24px;
    margin-top: 32px;
    box-shadow: var(--shadow-md);
}

.mentor-contact-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.mentor-contact-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--color-warning) 0%, #dd6b20 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.mentor-contact h3 {
    font-size: 18px;
    font-weight: 600;
}

.mentor-contact p {
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.6;
}

.feedback-form textarea {
    width: 100%;
    min-height: 100px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px;
    color: var(--text-primary);
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    margin-bottom: 12px;
}

.feedback-form textarea:focus {
    outline: none;
    border-color: var(--color-primary);
}

.feedback-form textarea::placeholder {
    color: var(--text-muted);
}

.btn-mentor {
    width: 100%;
    height: 44px;
    background: linear-gradient(135deg, var(--color-warning) 0%, #dd6b20 100%);
    border: none;
    border-radius: 8px;
    color: white;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-mentor:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(245, 158, 11, 0.4);
}

/* ========== DIRECTION CONTENT (Profile) ========== */

.direction-content {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.direction-details h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 4px;
}

.direction-progress {
    font-size: 14px;
    color: var(--text-muted);
}

/* ========== Студент: вкладки главной + проверка ДЗ ========== */
.student-home-tabs {
    display: flex;
    gap: 8px;
    margin: 20px 0 24px;
    flex-wrap: wrap;
}

.student-home-tab {
    padding: 10px 18px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-secondary);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.student-home-tab:hover {
    border-color: var(--color-primary);
    color: var(--text-primary);
}

.student-home-tab.active {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    border-color: transparent;
    color: #fff;
}

/* Вкладка «Онбординг» (iframe с HTML из БД) */
.onboarding-toolbar {
    max-width: 960px;
    margin: 16px auto 12px;
    padding: 12px 20px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    box-sizing: border-box;
}

.onboarding-toolbar--stacked {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
}

.onboarding-toolbar-label {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}

.onboarding-source-select {
    max-width: 100%;
    width: 100%;
    padding: 8px 12px;
    font-size: 15px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-primary);
    color: var(--text-primary);
}

@media (min-width: 560px) {
    .onboarding-toolbar--stacked .onboarding-source-select {
        max-width: 28rem;
    }
}

body.page-onboarding .onboarding-toolbar {
    margin-top: 8px;
}

.onboarding-frame-wrap {
    min-height: 72vh;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
}

.onboarding-page-iframe {
    width: 100%;
    min-height: 72vh;
    border: 0;
    display: block;
    vertical-align: top;
}

/* Отдельная страница onboarding.html — на всю ширину, без «коробки», прокрутка окна */
body.page-onboarding {
    min-height: 100vh;
}

body.page-onboarding .container--onboarding-full {
    max-width: none;
    width: 100%;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body.page-onboarding .onboarding-frame-wrap--fullpage {
    min-height: 0;
    border: none;
    border-radius: 0;
    overflow: visible;
    background: transparent;
}

body.page-onboarding .onboarding-frame-wrap--fullpage .onboarding-page-iframe {
    min-height: 0;
    width: 100%;
    display: block;
}

body.page-onboarding .onboarding-frame-wrap--fullpage .onboarding-placeholder,
body.page-onboarding .onboarding-frame-wrap--fullpage .onboarding-placeholder-msg {
    margin: 0 auto;
    max-width: 560px;
    padding: 48px 24px;
}

.onboarding-placeholder,
.onboarding-placeholder-msg {
    padding: 32px 24px;
    text-align: center;
    color: var(--text-secondary);
    font-size: 16px;
    line-height: 1.65;
}

.onboarding-placeholder-msg {
    color: var(--text-muted);
}

/* Блок опроса AI Hunt под iframe онбординга */
.onboarding-ai-hunt-root {
    max-width: 960px;
    margin: 32px auto 48px;
    padding: 24px 20px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
}

.onboarding-ai-hunt-heading {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0 0 16px;
    color: var(--text-primary);
}

.onboarding-ai-hunt-intro {
    color: var(--text-secondary);
    font-size: 15px;
    line-height: 1.55;
    margin-bottom: 16px;
}

.onboarding-ai-hunt-placeholder {
    color: var(--text-muted);
    font-size: 15px;
    margin: 0;
}

.onboarding-ai-hunt-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.onboarding-ai-hunt-btn {
    min-width: 200px;
}

.onboarding-ai-hunt-msg,
.onboarding-ai-hunt-error {
    font-size: 15px;
    margin: 0 0 8px;
    color: var(--text-secondary);
}

.onboarding-ai-hunt-error {
    color: var(--color-danger);
}

.onboarding-ai-hunt-results {
    margin-top: 20px;
}

.onboarding-ai-hunt-result-head {
    margin-bottom: 16px;
}

.onboarding-ai-hunt-result-title {
    font-size: 1.1rem;
    margin: 0 0 8px;
}

.onboarding-ai-hunt-score {
    font-weight: 600;
    margin: 8px 0;
}

.onboarding-ai-hunt-passed {
    color: var(--color-success);
    font-weight: 600;
}

.onboarding-ai-hunt-fail {
    color: var(--color-warning);
}

.onboarding-ai-hunt-feedback {
    margin-top: 12px;
    padding: 12px 14px;
    background: var(--bg-tertiary);
    border-radius: 8px;
    font-size: 14px;
    white-space: pre-wrap;
}

.onboarding-ai-hunt-qa {
    list-style: none;
    margin: 0;
    padding: 0;
}

.onboarding-ai-hunt-qa-item {
    padding: 14px 0;
    border-top: 1px solid var(--border-color);
}

.onboarding-ai-hunt-q {
    font-weight: 600;
    margin-bottom: 8px;
}

.onboarding-ai-hunt-a {
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.onboarding-ai-hunt-mini {
    font-size: 13px;
    color: var(--text-muted);
}

.hw-intro {
    margin-bottom: 16px;
    color: var(--text-secondary);
    max-width: 720px;
}

.hw-error {
    background: rgba(245, 101, 101, 0.12);
    border: 1px solid var(--color-danger);
    color: var(--color-danger);
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 16px;
}

.hw-label {
    display: block;
    margin: 12px 0 6px;
    font-weight: 600;
    color: var(--text-primary);
}

.hw-input {
    width: 100%;
    max-width: 640px;
    padding: 12px 14px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 15px;
}

.hw-theme-line {
    margin-bottom: 8px;
    color: var(--text-secondary);
}

.hw-subtopics {
    margin: 16px 0;
    padding: 12px 16px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    max-width: 640px;
}

.hw-subtopics label {
    display: block;
    margin: 6px 0;
    cursor: pointer;
    color: var(--text-primary);
}

.hw-msg {
    margin-top: 12px;
    min-height: 1.2em;
    color: var(--text-secondary);
}

.hw-list-wrap {
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--border-color);
}

.hw-list-title {
    font-size: 1.25rem;
    margin-bottom: 12px;
}

.hw-checks-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.hw-check-card {
    list-style: none;
    margin-bottom: 12px;
}

.hw-check-item {
    display: block;
    width: 100%;
    text-align: left;
    padding: 0;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: var(--bg-secondary);
    cursor: pointer;
    color: var(--text-primary);
    font: inherit;
    transition:
        transform 0.22s cubic-bezier(0.4, 0, 0.2, 1),
        box-shadow 0.22s ease,
        border-color 0.22s ease,
        background 0.22s ease;
}

.hw-check-item__layout {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 16px;
}

.hw-check-item__icon {
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #ffffff;
    flex-shrink: 0;
    transition: transform 0.22s ease;
}

.hw-check-item:hover .hw-check-item__icon,
.hw-check-item:focus-visible .hw-check-item__icon {
    transform: rotate(-3deg) scale(1.04);
}

.hw-check-item__icon--git {
    background:
        radial-gradient(circle at 35% 20%, rgba(255, 255, 255, 0.28), transparent 32%),
        linear-gradient(135deg, #24292f 0%, #57606a 100%);
    box-shadow: 0 8px 18px rgba(36, 41, 47, 0.22);
}

.hw-check-item__icon--yandex {
    background:
        radial-gradient(circle at 35% 20%, rgba(255, 255, 255, 0.34), transparent 32%),
        linear-gradient(135deg, #fc3f1d 0%, #ff7a45 100%);
    box-shadow: 0 8px 18px rgba(252, 63, 29, 0.24);
}

.hw-check-item__icon--neutral {
    background:
        radial-gradient(circle at 35% 20%, rgba(255, 255, 255, 0.34), transparent 32%),
        linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    box-shadow: 0 8px 18px var(--accent-shadow-light, rgba(102, 126, 234, 0.2));
}

.hw-check-item__body {
    flex: 1;
    min-width: 0;
}

.hw-ci-link-wrap {
    display: block;
    margin-top: 10px;
}

.hw-check-item:hover,
.hw-check-item:focus-visible {
    transform: translateY(-3px);
    border-color: color-mix(in srgb, var(--color-primary) 55%, var(--border-color));
    box-shadow: 0 10px 28px var(--accent-shadow-light, rgba(102, 126, 234, 0.18));
    outline: none;
}

.hw-check-item:active {
    transform: translateY(-1px);
}

.hw-check-item--pending {
    border-left: 3px solid rgba(234, 167, 45, 0.85);
}

.hw-check-item--completed {
    border-color: rgba(72, 187, 120, 0.55);
    background: rgba(72, 187, 120, 0.09);
    box-shadow: inset 0 0 0 1px rgba(72, 187, 120, 0.12);
}

.hw-check-item--completed:hover,
.hw-check-item--completed:focus-visible {
    border-color: rgba(72, 187, 120, 0.75);
    box-shadow: 0 10px 28px rgba(72, 187, 120, 0.16);
}

[data-theme="dark"] .hw-check-item--completed {
    border-color: rgba(72, 187, 120, 0.45);
    background: rgba(72, 187, 120, 0.12);
}

.hw-ci-external {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border-radius: 8px;
    border: 1px solid color-mix(in srgb, var(--color-primary) 45%, var(--border-color));
    background: var(--bg-secondary);
    color: var(--color-primary);
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.hw-ci-external:hover {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: #fff;
}

.hw-check-item .hw-ci-title {
    font-weight: 600;
    margin-bottom: 4px;
}

.hw-check-item .hw-ci-meta {
    font-size: 13px;
    color: var(--text-muted);
}

.hw-list-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.hw-list-sort {
    min-width: 240px;
}

.hw-list-sort .hw-input {
    min-width: 240px;
}

@media (prefers-reduced-motion: reduce) {
    .hw-check-item {
        transition: none;
    }
    .hw-check-item:hover,
    .hw-check-item:focus-visible {
        transform: none;
    }
}

.hw-detail {
    margin-top: 8px;
}

.hw-back {
    margin-bottom: 16px;
}

.hw-meta {
    color: var(--text-muted);
    margin-bottom: 12px;
}

.hw-score {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-success);
    margin-bottom: 20px;
}

.hw-detail-block {
    margin-bottom: 24px;
}

.hw-detail-block h4 {
    margin-bottom: 8px;
    font-size: 1rem;
}

.hw-md {
    line-height: 1.55;
    color: var(--text-primary);
}

.hw-md pre, .hw-md code {
    background: var(--bg-tertiary);
    border-radius: 6px;
    padding: 2px 6px;
    font-size: 0.9em;
}

.hw-pre {
    white-space: pre-wrap;
    background: var(--bg-tertiary);
    padding: 12px;
    border-radius: 8px;
    font-size: 14px;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.hw-staff-filters {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(160px, 220px) auto;
    gap: 12px 16px;
    align-items: end;
    margin-bottom: 16px;
    padding: 14px 16px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
}

.hw-staff-filters > label {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--text-secondary);
}

/* ---------- Домашние задания: студент / ментор / HR (единый стиль) ---------- */

.hw-page {
    max-width: 800px;
}

.hw-intro-card {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px 18px;
    margin-bottom: 20px;
}

.hw-intro-card .hw-intro {
    margin-bottom: 0;
}

.hw-form-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px 20px 18px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-md);
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.hw-form-card:focus-within {
    border-color: rgba(102, 126, 234, 0.35);
    box-shadow: var(--shadow-md), 0 0 0 3px rgba(102, 126, 234, 0.12);
}

.hw-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.hw-form__header {
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}

.hw-form__eyebrow {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.hw-form__theme {
    margin: 0;
    font-size: 1.05rem;
    color: var(--text-primary);
}

.hw-form__body {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.hw-form__field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.hw-form__field .hw-label {
    margin: 0;
}

.hw-field-hint {
    margin: 0;
    font-size: 13px;
    line-height: 1.45;
    color: var(--text-muted);
}

.hw-form__actions {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding-top: 4px;
    border-top: 1px solid var(--border-color);
}

.hw-form__field .hw-input,
.hw-form__field .hw-subtopics {
    max-width: none;
    width: 100%;
}

.hw-form__field.hw-subtopics {
    margin: 0;
}

.hw-list-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px 20px 16px;
    margin-top: 24px;
    border-top: none;
    box-shadow: var(--shadow-md);
}

.hw-list-card .hw-list-title {
    margin-top: 0;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-color);
}

.hw-detail-panel {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px 20px 8px;
    margin-top: 16px;
    box-shadow: var(--shadow-md);
}

.hw-detail-title {
    font-size: 1.35rem;
    margin-bottom: 14px;
    color: var(--text-primary);
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
    position: relative;
}

.hw-detail-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -1px;
    width: 72px;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--color-primary), var(--color-secondary));
}

.hw-detail-meta {
    margin-bottom: 16px;
}

.hw-meta-grid {
    display: flex;
    flex-direction: column;
    gap: 0;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    background: var(--bg-tertiary);
}

.hw-meta-row {
    display: grid;
    grid-template-columns: minmax(120px, 160px) 1fr;
    gap: 12px;
    padding: 10px 14px;
    border-bottom: 1px solid var(--border-color);
    align-items: center;
}

.hw-meta-row:last-child {
    border-bottom: none;
}

.hw-meta-row--full {
    grid-template-columns: 1fr;
}

.hw-meta-label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.hw-meta-value {
    font-size: 15px;
    color: var(--text-primary);
    word-break: break-word;
}

.hw-meta-linkblock {
    padding: 14px 16px 16px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-color);
    border-radius: 0 0 10px 10px;
}

.hw-work-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
    font-size: 15px;
    color: var(--color-primary);
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: color 0.15s, border-color 0.15s;
}

.hw-work-link:hover {
    color: var(--color-primary-hover);
    border-bottom-color: var(--color-primary-hover);
}

.hw-work-link--small {
    font-size: 14px;
    padding: 6px 10px;
    border-radius: 8px;
    border: 1px solid var(--color-primary);
    border-bottom: 1px solid var(--color-primary);
    background: rgba(102, 126, 234, 0.08);
}

[data-theme="dark"] .hw-work-link--small {
    background: rgba(124, 58, 237, 0.15);
}

.hw-work-link--small:hover {
    background: rgba(102, 126, 234, 0.16);
}

.hw-url-preview {
    margin-top: 10px;
    padding: 10px 12px;
    border-radius: 8px;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.06), rgba(118, 75, 162, 0.06));
    border: 1px solid rgba(102, 126, 234, 0.22);
    border-left: 3px solid var(--color-primary);
}

[data-theme="dark"] .hw-url-preview {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.12), rgba(139, 92, 246, 0.08));
    border-color: rgba(124, 58, 237, 0.35);
}

.hw-url-preview__label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--color-primary);
    margin-bottom: 4px;
}

.hw-url-preview__text {
    display: block;
    font-size: 13px;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    color: var(--text-primary);
    word-break: break-all;
    line-height: 1.5;
}

.hw-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
}

.hw-badge--success {
    background: rgba(72, 187, 120, 0.18);
    color: var(--color-success);
}

.hw-badge--danger {
    background: rgba(245, 101, 101, 0.15);
    color: var(--color-danger);
}

.hw-badge--warn {
    background: rgba(237, 137, 54, 0.18);
    color: var(--color-warning);
}

.hw-badge--neutral {
    background: var(--bg-hover);
    color: var(--text-secondary);
}

.hw-score-pill {
    display: inline-block;
    font-size: 1rem;
    padding: 8px 14px;
    border-radius: 10px;
    background: rgba(72, 187, 120, 0.15);
    margin-bottom: 18px;
}

.hw-score-pill--neutral {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
    font-weight: 600;
}

.hw-score-pill--success {
    background: rgba(72, 187, 120, 0.2);
    color: var(--color-success);
    border: 1px solid rgba(72, 187, 120, 0.45);
    font-weight: 600;
}

.hw-detail-block--framed {
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 14px 16px 16px;
}

.hw-detail-block--framed h4 {
    margin-top: 0;
    color: var(--text-primary);
    font-size: 0.95rem;
    letter-spacing: 0.01em;
}

/* Устаревшая разметка hw-check-row — оставлена для совместимости */
.hw-check-row {
    margin-bottom: 12px;
}

.hw-staff-filter-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--text-secondary);
    font-size: 13px;
}

.hw-staff-page .page-title {
    margin-bottom: 8px;
}

/* Страницы ДЗ/интервью во iframe вкладок главной (main.css — доступен внутри iframe). */
html.app-embedded,
body.app-embedded {
    background: transparent !important;
    background-image: none !important;
}

html.app-embedded::before {
    display: none !important;
}

body.app-embedded .container {
    max-width: none;
    padding: 0;
    margin: 0;
}

body.app-embedded .page-title,
body.app-embedded .hw-staff-page .page-subtitle {
    display: none;
}

body.app-embedded .hw-staff-card {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    margin-bottom: 0;
}

body.app-embedded .hw-staff-card--accent,
body.app-embedded #hwMentorPendingSection.hw-staff-card {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    margin-bottom: 20px;
    border-left: none;
}

body.app-embedded #hwMentorPendingSection .hw-list-title--inline,
body.app-embedded #hwMentorPendingSection .hw-checks-list {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
}

body.app-embedded #hwMentorPendingSection .hw-staff-hint {
    background: var(--bg-tertiary);
    padding: 12px 14px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    margin-bottom: 14px;
}

body.app-embedded .hw-list-title--inline {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 14px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border-color);
}

body.app-embedded .hw-staff-filters {
    margin-bottom: 14px;
}

body.app-embedded .hw-staff-list-wrap {
    margin-top: 0;
    padding-top: 0;
}

body.app-embedded .hw-empty-state {
    background: var(--bg-tertiary);
}

body.app-embedded #hwMentorPendingSection + .hw-staff-card {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

body.app-embedded .hw-staff-detail.hw-detail-panel {
    margin-top: 20px;
    padding: 20px 0 0;
    border: none;
    border-top: 1px solid var(--border-color);
    border-radius: 0;
    box-shadow: none;
    background: transparent;
}

.hw-staff-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px 20px 18px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-md);
}

.hw-staff-card--accent {
    border-left: 4px solid var(--color-secondary);
}

/* Очередь ментора: чуть разные фоны, без выхода из палитры сайта */
#hwMentorPendingSection.hw-staff-card {
    background: linear-gradient(
        168deg,
        var(--bg-secondary) 0%,
        rgba(102, 126, 234, 0.055) 42%,
        var(--bg-secondary) 100%
    );
}

[data-theme="dark"] #hwMentorPendingSection.hw-staff-card {
    background: linear-gradient(
        168deg,
        var(--bg-secondary) 0%,
        rgba(124, 58, 237, 0.09) 42%,
        var(--bg-secondary) 100%
    );
}

#hwMentorPendingSection .hw-list-title--inline {
    background: var(--bg-tertiary);
    padding: 10px 14px;
    margin-bottom: 14px;
    border-radius: 8px;
    border-bottom: none;
    box-shadow: inset 0 0 0 1px var(--border-color);
}

#hwMentorPendingSection .hw-staff-hint {
    background: var(--bg-tertiary);
    padding: 12px 14px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    margin-bottom: 14px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

#hwMentorPendingSection .hw-checks-list {
    margin: 0;
    padding: 10px;
    border-radius: 10px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
}

#hwMentorPendingSection .hw-check-card .hw-check-item {
    background: var(--bg-secondary);
}

#hwMentorPendingSection .hw-check-card:nth-child(even) .hw-check-item {
    background: rgba(102, 126, 234, 0.06);
}

[data-theme="dark"] #hwMentorPendingSection .hw-check-card:nth-child(even) .hw-check-item {
    background: rgba(124, 58, 237, 0.1);
}

#hwMentorPendingSection .hw-ci-external {
    background: var(--bg-secondary);
    border-color: rgba(102, 126, 234, 0.45);
}

[data-theme="dark"] #hwMentorPendingSection .hw-ci-external {
    border-color: rgba(167, 139, 250, 0.5);
}

.hw-staff-hint {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0 0 16px;
    max-width: 720px;
    line-height: 1.5;
}

.hw-list-title--inline {
    font-size: 1.15rem;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-color);
}

.hw-staff-filter-field {
    flex: 1;
    min-width: 200px;
    max-width: 400px;
}

.hw-staff-filter-field label {
    display: block;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 6px;
    color: var(--text-secondary);
}

.hw-staff-list-wrap {
    margin-top: 16px;
    padding-top: 4px;
}

.hw-staff-detail.hw-detail-panel {
    margin-top: 8px;
}

.hw-mentor-feedback-box {
    margin-top: 20px;
    padding: 18px;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background: var(--bg-tertiary);
    border-top: 3px solid var(--color-primary);
}

.hw-mentor-feedback-heading {
    margin: 0 0 12px;
    font-size: 1rem;
}

.hw-textarea {
    resize: vertical;
    min-height: 120px;
    max-width: 100%;
    font-family: inherit;
    line-height: 1.5;
}

.hw-check-item .hw-ci-meta {
    color: var(--text-secondary);
}

.hw-ci-link-hint {
    margin-top: 6px;
    font-size: 12px;
    color: var(--text-muted);
}

.hw-empty-hint {
    padding: 16px 12px;
    text-align: center;
    color: var(--text-muted);
    font-size: 14px;
}

.hw-empty-state {
    list-style: none;
    margin: 0;
    padding: 36px 20px;
    text-align: center;
    background: var(--bg-tertiary);
    border: 1px dashed var(--border-color);
    border-radius: 14px;
}

.hw-empty-state__icon {
    font-size: 48px;
    line-height: 1;
    color: color-mix(in srgb, var(--text-muted) 55%, var(--color-primary));
    margin-bottom: 12px;
}

.hw-empty-state__text {
    margin: 0;
    font-size: 15px;
    color: var(--text-secondary);
}

@media (max-width: 720px) {
    .hw-staff-filters {
        grid-template-columns: 1fr;
    }

    .hw-staff-filters .btn {
        width: 100%;
    }
}

@media (max-width: 520px) {
    .hw-meta-row {
        grid-template-columns: 1fr;
        gap: 4px;
    }

    .hw-list-head {
        flex-direction: column;
        align-items: stretch;
    }

    .hw-list-sort,
    .hw-list-sort .hw-input {
        min-width: 0;
        width: 100%;
    }
}

/* ============================================================
   Акцентная градиентная шапка (все страницы платформы)
   ============================================================ */
.header {
    position: relative;
    overflow: hidden;
    background: var(--accent-gradient);
    border-bottom: none;
    color: var(--header-fg);
    box-shadow: 0 4px 24px var(--accent-shadow-soft);
}

.header::before,
.header::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    filter: blur(50px);
    pointer-events: none;
    z-index: 0;
}

.header::before {
    width: 320px;
    height: 320px;
    right: -80px;
    top: -160px;
    background: color-mix(in srgb, var(--color-secondary) 42%, transparent);
}

.header::after {
    width: 200px;
    height: 200px;
    left: 22%;
    bottom: -120px;
    background: color-mix(in srgb, #ffffff 22%, transparent);
}

.header > * {
    position: relative;
    z-index: 1;
}

.header .logo {
    background: none;
    -webkit-background-clip: unset;
    background-clip: unset;
    -webkit-text-fill-color: var(--header-fg-strong);
    color: var(--header-fg-strong);
}

.header .logo i,
.header .nav-item:not(.active) i,
.header .home-tab:not(.active) i,
.header .layout-settings-btn i,
.header .notification-bell-btn i {
    color: var(--header-fg-strong);
}

.header .user-name {
    color: var(--header-fg-strong);
}

.header .user-role {
    color: var(--header-fg-muted);
}

.header .header-tool-btn {
    background: var(--header-glass-bg);
    border-color: var(--header-glass-border);
    color: var(--header-fg-strong);
}

.header .header-tool-btn:hover {
    background: var(--header-glass-hover);
    color: var(--header-fg-strong);
    border-color: var(--header-glass-border);
}

/* Профиль: без стеклянной «таблетки» — только круг с инициалами и имя */
.header .user-menu-btn {
    width: auto;
    height: auto;
    padding: 0;
    gap: 10px;
    border: none;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-radius: 0;
    box-shadow: none;
}

.header .user-menu-btn:hover {
    background: transparent;
    border: none;
    color: var(--header-fg-strong);
}

.header .user-menu-btn:active {
    transform: none;
}

.header .user-menu-btn .user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--header-glass-bg);
    border: 1px solid var(--header-glass-border);
    color: var(--header-avatar-fg);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.12);
    flex-shrink: 0;
    font-size: 14px;
    font-weight: 700;
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.header .user-menu-btn:hover .user-avatar {
    background: var(--header-glass-hover);
    border-color: var(--header-glass-border);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.16);
}

.header .user-menu-btn .user-name {
    font-weight: 600;
    font-size: 14px;
    line-height: 1.2;
    white-space: nowrap;
}

.header .user-menu:hover {
    background: var(--header-glass-hover);
}

.header .nav-item {
    color: var(--header-fg-strong);
    background: var(--header-glass-bg);
    border: 1px solid var(--header-glass-border);
    font-weight: 600;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.header .nav-item:hover {
    background: var(--header-glass-hover);
    color: var(--header-fg-strong);
}

.header .nav-item.active {
    background: var(--header-active-bg);
    color: var(--header-active-fg);
    border-color: transparent;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
}

.header .nav-item.active i {
    color: var(--header-active-fg);
}

.header .nav-item.nav-item--ai-learning {
    color: var(--header-fg-strong);
    background: var(--header-glass-bg);
}

.header .nav-item.nav-item--ai-learning i {
    color: var(--header-fg-strong);
}

.header .nav-item.nav-item--ai-learning:hover,
.header .nav-item.nav-item--ai-learning.nav-item--ai-learning-active {
    background: var(--header-active-bg);
    color: var(--nav-ai-learning-hover);
}

.header .nav-item.nav-item--ai-learning:hover i,
.header .nav-item.nav-item--ai-learning.nav-item--ai-learning-active i {
    color: var(--nav-ai-learning-hover);
}

.header.header--home {
    box-shadow: 0 6px 28px var(--accent-shadow-soft);
}

/* ---------- Вкладки главной в шапке (единый вид на всех страницах сайта) ---------- */
.nav-menu--home-tabs {
    display: flex;
    flex-wrap: nowrap;
    gap: 4px;
    padding: 3px;
    background: var(--header-glass-bg);
    border: 1px solid var(--header-glass-border);
    border-radius: 12px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    position: relative;
}

.home-tab-slider {
    position: absolute;
    top: 3px;
    left: 0;
    height: calc(100% - 6px);
    border-radius: 10px;
    background: var(--header-active-bg);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
    pointer-events: none;
    z-index: 0;
    transform: translate3d(0, 0, 0);
    transition:
        transform 0.38s cubic-bezier(0.34, 1.2, 0.64, 1),
        width 0.38s cubic-bezier(0.34, 1.2, 0.64, 1),
        opacity 0.2s ease;
    will-change: transform, width;
}

.nav-menu--home-tabs.nav-menu--drawer .home-tab-slider {
    display: none !important;
}

.nav-menu--home-tabs::-webkit-scrollbar {
    display: none;
}

/* Центр может сжиматься: иначе width:max-content раздувает колонку и вкладки наезжают (EDU-530) */
.header-top > .nav-menu.nav-menu--home-tabs {
    flex: 1 1 auto;
    min-width: 0;
    width: max-content;
    max-width: 100%;
    justify-content: center;
}

.header.header--with-tabs .header-top {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
}

.header.header--with-tabs .header-top > .logo {
    justify-self: start;
    min-width: 0;
}

.header.header--with-tabs .header-top > .nav-menu--home-tabs {
    justify-self: center;
    min-width: 0;
    max-width: 100%;
}

.header.header--with-tabs .header-top > .header-actions {
    justify-self: end;
}

@media (max-width: 768px) {
    .header.header--with-tabs .header-top {
        display: flex;
        justify-content: space-between;
    }
}

/* Overflow-driven drawer выше 768px (body.nav-drawer-mode из app-layout.js) */
body.nav-drawer-mode .header.header--with-tabs .header-top {
    display: flex;
    justify-content: space-between;
}

body.nav-drawer-mode .nav-toggle:not([hidden]) {
    display: inline-flex !important;
}

body.nav-drawer-mode .nav-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 10050;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.22s ease, visibility 0.22s ease;
}

body.nav-drawer-mode .nav-backdrop.is-active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

body.nav-drawer-mode.nav-drawer-open {
    overflow: hidden;
}

body.nav-drawer-mode.nav-drawer-open .header {
    z-index: 10061;
    overflow: visible;
}

.home-tab {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    appearance: none;
    border: 1px solid transparent;
    background: transparent;
    color: var(--header-fg-strong);
    padding: 8px 14px;
    border-radius: 10px;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    text-decoration: none;
    transition: background 0.2s ease, color 0.28s ease, box-shadow 0.2s ease;
    flex: 0 0 auto;
    font-family: inherit;
    line-height: 1.2;
    position: relative;
    z-index: 1;
}

.home-tab i {
    color: var(--header-fg-strong);
    transition: color 0.28s ease;
}

.home-tab:hover {
    background: var(--header-glass-hover);
    color: var(--header-fg-strong);
}

.home-tab:hover i {
    color: var(--header-fg-strong);
}

/* Активная вкладка: фон рисует .home-tab-slider, не сама кнопка */
.nav-menu--home-tabs:not(.nav-menu--drawer) .home-tab.active {
    background: transparent;
    color: var(--header-active-fg);
    box-shadow: none;
    border-color: transparent;
}

.nav-menu--home-tabs:not(.nav-menu--drawer) .home-tab.active:hover {
    background: transparent;
}

.home-tab.active {
    color: var(--header-active-fg);
}

.home-tab.active i {
    color: var(--header-active-fg);
}

.home-tab[hidden] {
    display: none !important;
}

.nav-menu--home-tabs.nav-menu--compact .home-tab:not(.active) .home-tab-label,
.nav-menu.nav-menu--compact .nav-item:not(.active) .nav-item-label {
    display: none;
}

.nav-menu--home-tabs.nav-menu--compact .home-tab:not(.active),
.nav-menu.nav-menu--compact .nav-item:not(.active) {
    padding-left: 9px;
    padding-right: 9px;
}

.nav-menu--home-tabs.nav-menu--compact .home-tab.active,
.nav-menu.nav-menu--compact .nav-item.active {
    padding-left: 12px;
    padding-right: 12px;
}

.home-tab i,
.nav-item i {
    pointer-events: none;
}

.header .notification-bell-btn {
    background: var(--header-glass-bg);
    border-color: var(--header-glass-border);
    color: var(--header-fg-strong);
}

.header .notification-bell-btn:hover {
    background: var(--header-glass-hover);
    color: var(--header-fg-strong);
    border-color: var(--header-glass-border);
}

.header .nav-toggle {
    background: var(--header-glass-bg);
    border-color: var(--header-glass-border);
    color: var(--header-fg-strong);
}

.header .nav-toggle:hover {
    background: var(--header-glass-hover);
    color: var(--header-fg-strong);
}

@media (max-width: 768px) {
    .header .nav-menu.nav-menu--drawer .nav-item {
        background: var(--bg-tertiary);
        border-color: var(--border-color);
        color: var(--text-primary);
    }
}

/* Финальный override: drawer вкладок главной (в т.ч. overflow-driven выше 768px, EDU-530)
   должен выигрывать правила обычной горизонтальной навигации. */
body > .nav-menu.nav-menu--home-tabs.nav-menu--drawer {
    box-sizing: border-box !important;
    position: fixed !important;
    top: calc(64px + env(safe-area-inset-top, 0px)) !important;
    right: calc(10px + env(safe-area-inset-right, 0px)) !important;
    bottom: 10px !important;
    left: auto !important;
    width: min(340px, calc(100% - 20px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px))) !important;
    inline-size: min(340px, calc(100% - 20px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px))) !important;
    max-width: calc(100% - 20px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)) !important;
    max-inline-size: calc(100% - 20px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)) !important;
    height: auto !important;
    max-height: calc(100dvh - 74px - env(safe-area-inset-top, 0px)) !important;
    margin: 0 !important;
    padding: 16px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 10px !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    border: 1px solid color-mix(in srgb, var(--border-color) 82%, var(--color-primary)) !important;
    border-radius: 24px !important;
    background:
        radial-gradient(circle at 100% 0%, color-mix(in srgb, var(--color-primary) 14%, transparent), transparent 36%),
        color-mix(in srgb, var(--bg-secondary) 96%, #0f172a) !important;
    box-shadow: -18px 18px 48px rgba(15, 23, 42, 0.28) !important;
    contain: layout paint;
    transform: translateX(calc(100% + 18px)) !important;
    mask-image: none !important;
    -webkit-mask-image: none !important;
    scrollbar-width: thin;
}

body > .nav-menu.nav-menu--home-tabs.nav-menu--drawer.is-open {
    transform: translateX(0) !important;
}

body > .nav-menu.nav-menu--home-tabs.nav-menu--drawer::before {
    content: 'Разделы главной';
    display: block;
    flex: 0 0 auto;
    padding: 0 4px 4px;
    color: var(--text-muted);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    line-height: 1.2;
    text-transform: uppercase;
}

body > .nav-menu.nav-menu--home-tabs.nav-menu--drawer .home-tab {
    box-sizing: border-box !important;
    width: 100% !important;
    inline-size: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 52px !important;
    padding: 13px 14px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    gap: 10px !important;
    flex: 0 1 auto !important;
    border: 1px solid color-mix(in srgb, var(--border-color) 82%, var(--color-primary)) !important;
    border-radius: 16px !important;
    background: color-mix(in srgb, var(--bg-tertiary) 84%, transparent) !important;
    color: var(--text-primary) !important;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.05) !important;
    font-size: 0.95rem !important;
    line-height: 1.25 !important;
    text-align: left !important;
    white-space: normal !important;
    overflow: hidden !important;
}

body > .nav-menu.nav-menu--home-tabs.nav-menu--drawer .home-tab-label {
    display: block !important;
    flex: 1 1 auto;
    min-width: 0;
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: normal;
    white-space: normal;
}

body > .nav-menu.nav-menu--home-tabs.nav-menu--drawer .home-tab i {
    flex: 0 0 22px;
    width: 22px;
    min-width: 22px;
    color: var(--color-primary) !important;
}

body > .nav-menu.nav-menu--home-tabs.nav-menu--drawer .home-tab.active {
    background:
        radial-gradient(circle at 100% 0%, rgba(255, 255, 255, 0.24), transparent 42%),
        linear-gradient(135deg, var(--color-primary), var(--color-secondary)) !important;
    color: #ffffff !important;
    border-color: transparent !important;
    box-shadow: 0 14px 28px var(--accent-shadow-soft) !important;
}

body > .nav-menu.nav-menu--home-tabs.nav-menu--drawer .home-tab.active i {
    color: #ffffff !important;
}

@media (max-width: 380px) {
    body > .nav-menu.nav-menu--home-tabs.nav-menu--drawer {
        top: calc(58px + env(safe-area-inset-top, 0px)) !important;
        right: calc(8px + env(safe-area-inset-right, 0px)) !important;
        bottom: 8px !important;
        width: calc(100% - 16px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)) !important;
        inline-size: calc(100% - 16px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)) !important;
        max-width: calc(100% - 16px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)) !important;
        max-inline-size: calc(100% - 16px - env(safe-area-inset-left, 0px) - env(safe-area-inset-right, 0px)) !important;
        left: auto !important;
        max-height: calc(100dvh - 66px - env(safe-area-inset-top, 0px)) !important;
        padding: 12px !important;
        gap: 8px !important;
        border-radius: 20px !important;
    }

    body > .nav-menu.nav-menu--home-tabs.nav-menu--drawer .home-tab {
        min-height: 48px !important;
        padding: 11px 12px !important;
        gap: 8px !important;
        border-radius: 14px !important;
        font-size: 0.9rem !important;
    }
}



/* DEV-2310: центрированная форма обратной связи ментора */
html.hw-feedback-modal-open,
body.hw-feedback-modal-open { overflow: hidden !important; }
body.app-embedded.hw-feedback-modal-open > :not(#hwMentorFeedbackModal) {
    visibility: hidden !important;
}
.hw-feedback-modal {
    position: fixed;
    inset: 0;
    z-index: 12000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    box-sizing: border-box;
}
.hw-feedback-modal[hidden] { display: none !important; }
.hw-feedback-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.64);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}
.hw-feedback-modal__panel {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    width: min(920px, 100%);
    max-height: min(94vh, 820px);
    overflow: hidden;
    color: var(--text-primary, #1e293b);
    background: var(--bg-secondary, #fff);
    border: 1px solid color-mix(in srgb, var(--border-color, #e2e8f0) 82%, transparent);
    border-radius: 18px;
    box-shadow: 0 24px 70px rgba(3, 7, 18, 0.38);
    animation: hwFeedbackModalIn 0.22s ease-out;
    font-family: var(--user-font-family, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);
}
@keyframes hwFeedbackModalIn {
    from { opacity: 0; transform: translateY(14px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
.hw-feedback-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-shrink: 0;
    padding: 13px 18px;
    color: var(--text-primary, #1e293b);
    background: var(--bg-secondary, #fff);
    border-bottom: 1px solid var(--border-color, #e2e8f0);
}
.hw-feedback-modal__title {
    margin: 0;
    color: var(--text-primary, #1e293b);
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.25;
}
.hw-feedback-modal__close {
    position: static;
    z-index: 2;
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    padding: 0;
    appearance: none;
    color: var(--text-secondary, #64748b);
    font-size: 1rem;
    cursor: pointer;
    background: var(--bg-tertiary, #f1f5f9);
    border: none;
    border-radius: 11px;
    transition: background 0.15s ease, transform 0.15s ease;
}
.hw-feedback-modal__close:hover {
    color: var(--text-primary, #1e293b);
    background: var(--bg-hover, #e2e8f0);
    transform: none;
}
.hw-feedback-modal__close:focus-visible,
.hw-feedback-modal__details-toggle:focus-visible {
    outline: 3px solid color-mix(in srgb, var(--color-primary, #6366f1) 28%, transparent);
    outline-offset: 2px;
}
.hw-feedback-modal__body {
    flex: 1;
    width: 100%;
    min-height: 0;
    padding: 14px 18px 5px;
    overflow-y: auto;
    box-sizing: border-box;
    scrollbar-width: thin;
    font-size: 0.9rem;
}
.hw-feedback-modal__meta {
    margin-bottom: 13px;
    padding: 0;
    background: transparent;
    border: 0;
    border-radius: 0;
}
.hw-feedback-modal__student {
    display: flex;
    align-items: center;
    gap: 11px;
    min-width: 0;
    padding: 10px 12px;
    background: color-mix(in srgb, var(--color-primary, #6366f1) 5%, var(--bg-primary, #f8fafc));
    border: 1px solid color-mix(in srgb, var(--color-primary, #6366f1) 14%, var(--border-color, #e2e8f0));
    border-radius: 12px;
}
.hw-feedback-modal__student-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    color: var(--color-primary, #6366f1);
    background: color-mix(in srgb, var(--color-primary, #6366f1) 12%, transparent);
    border-radius: 10px;
}
.hw-feedback-modal__student-copy {
    flex: 1 1 auto;
    min-width: 0;
}
.hw-feedback-modal__student-line {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}
.hw-feedback-modal__student-line strong {
    overflow: hidden;
    color: var(--text-primary, #1e293b);
    font-size: 0.86rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.hw-feedback-modal__student-copy > span {
    display: block;
    margin-top: 2px;
    overflow: hidden;
    color: var(--text-muted, #64748b);
    font-size: 0.74rem;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.hw-feedback-modal__student .hw-badge {
    flex: 0 0 auto;
    padding: 3px 7px;
    font-size: 0.67rem;
}
.hw-feedback-modal__work-link {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 6px;
    padding: 7px 10px;
    color: var(--color-primary, #6366f1);
    font-size: 0.76rem;
    font-weight: 700;
    text-decoration: none;
    background: var(--bg-secondary, #fff);
    border: 1px solid color-mix(in srgb, var(--color-primary, #6366f1) 25%, var(--border-color, #e2e8f0));
    border-radius: 9px;
}
.hw-feedback-modal__work-link:hover {
    color: var(--color-primary-hover, #4f46e5);
    background: color-mix(in srgb, var(--color-primary, #6366f1) 6%, var(--bg-secondary, #fff));
}
.hw-feedback-modal__field { margin-bottom: 11px; }
.hw-feedback-modal__field .hw-label {
    margin-top: 0;
    font-size: 0.86rem;
}
.hw-feedback-modal__field .hw-input {
    max-width: none;
    border-radius: 12px;
    background: var(--bg-primary, #f8fafc);
    font-size: 0.88rem;
}
.hw-feedback-modal__field .hw-input:focus {
    border-color: var(--color-primary, #6366f1);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--color-primary, #6366f1) 16%, transparent);
}
.hw-feedback-modal__field .hw-textarea {
    min-height: 76px;
    resize: vertical;
    line-height: 1.45;
}
#hwMfFeedback { min-height: 96px; }
.hw-feedback-modal__field-hint {
    margin: -1px 0 5px;
    color: var(--text-muted, #64748b);
    font-size: 0.76rem;
    line-height: 1.45;
}
.hw-feedback-modal .sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
.hw-feedback-modal__details-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    width: 100%;
    margin: 0 0 8px;
    padding: 9px 11px;
    color: var(--text-primary, #1e293b);
    font: inherit;
    font-weight: 700;
    text-align: left;
    cursor: pointer;
    background: var(--bg-tertiary, #f1f5f9);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 10px;
    font-size: 0.86rem;
    transition: border-color 0.15s ease, background 0.15s ease;
}
.hw-feedback-modal__details-toggle:hover {
    border-color: color-mix(in srgb, var(--color-primary, #6366f1) 45%, var(--border-color, #e2e8f0));
    background: color-mix(in srgb, var(--color-primary, #6366f1) 7%, var(--bg-tertiary, #f1f5f9));
}
.hw-feedback-modal__details-label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}
.hw-feedback-modal__details-label > i { color: var(--color-primary, #6366f1); }
.hw-feedback-modal__details-label small {
    margin-left: 5px;
    color: var(--text-muted, #64748b);
    font-size: 0.75rem;
    font-weight: 500;
}
.hw-feedback-modal__details-chevron { transition: transform 0.18s ease; }
.hw-feedback-modal__details-toggle[aria-expanded="true"] .hw-feedback-modal__details-chevron {
    transform: rotate(180deg);
}
.hw-feedback-modal__crs {
    margin-bottom: 2px;
    padding: 12px 13px 1px;
    background: color-mix(in srgb, var(--bg-tertiary, #f1f5f9) 64%, transparent);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 14px;
}
.hw-feedback-modal__crs[hidden] { display: none !important; }
.hw-feedback-modal__crs-hint {
    margin: 0 0 10px;
    color: var(--text-muted, #64748b);
    font-size: 0.76rem;
    line-height: 1.45;
}
.hw-feedback-modal__details-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}
.hw-feedback-modal__field--score { max-width: 190px; }
.hw-feedback-modal__message {
    min-height: 20px;
    margin: 4px 0 6px;
    font-size: 0.86rem;
    font-weight: 600;
}
.hw-feedback-modal__message.is-error {
    padding: 10px 12px;
    color: var(--color-danger, #dc2626);
    background: color-mix(in srgb, var(--color-danger, #dc2626) 9%, transparent);
    border-radius: 10px;
}
.hw-feedback-modal__footer {
    display: flex;
    flex-shrink: 0;
    justify-content: flex-end;
    gap: 10px;
    width: 100%;
    padding: 9px 18px 13px;
    box-sizing: border-box;
    background: var(--bg-secondary, #fff);
    border-top: 0;
}
.hw-feedback-modal__footer .btn {
    min-height: 40px;
    padding: 9px 16px;
    border-radius: 10px;
    font-size: 0.86rem;
    font-weight: 700;
}
.hw-feedback-modal__footer .btn-primary {
    box-shadow: 0 6px 14px color-mix(in srgb, var(--color-primary, #6366f1) 24%, transparent);
}
.hw-req { color: var(--color-danger, #dc2626); }

@media (max-width: 640px) {
    .hw-feedback-modal { align-items: flex-end; padding: 8px; }
    .hw-feedback-modal__panel {
        width: min(920px, 100%);
        max-height: min(97vh, 820px);
        border-radius: 16px;
    }
    .hw-feedback-modal__header { padding: 12px 14px; }
    .hw-feedback-modal__close { width: 34px; height: 34px; }
    .hw-feedback-modal__body { padding: 14px 14px 5px; }
    .hw-feedback-modal__meta { padding: 0; }
    .hw-feedback-modal__student {
        align-items: flex-start;
        flex-wrap: wrap;
    }
    .hw-feedback-modal__student-copy { min-width: calc(100% - 48px); }
    .hw-feedback-modal__work-link { margin-left: 45px; }
    .hw-feedback-modal__details-grid { grid-template-columns: 1fr; gap: 0; }
    .hw-feedback-modal__footer { padding: 9px 14px 12px; }
    .hw-feedback-modal__footer .btn { flex: 1; padding-inline: 12px; }
}

@media (max-width: 420px) {
    .hw-feedback-modal { padding: 8px; }
    .hw-feedback-modal__title { font-size: 1.05rem; }
}

@media (prefers-reduced-motion: reduce) {
    .hw-feedback-modal__panel { animation: none; }
    .hw-feedback-modal__close,
    .hw-feedback-modal__details-toggle,
    .hw-feedback-modal__details-chevron { transition: none; }
}
