/* Основные стили */

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    margin: 0;
    padding: 0;
    background: linear-gradient(120deg, #f6f8fb 0%, #fff 30%, #fdeada 100%);
    color: #334155;
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}


/* Улучшенная навигация */

.topbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: linear-gradient(135deg, #326E89 0%, #326E89 100%);
    color: #e2e8f0;
    padding: 0;
    box-shadow: 0 10px 30px rgba(50, 110, 137, 0.2);
    backdrop-filter: blur(20px);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 70px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #e2e8f0;
    font-weight: 800;
    font-size: 1.25rem;
    transition: all 0.3s ease;
}

.brand:hover {
    color: #fff;
    transform: translateY(-1px);
}

.brand-icon {
    font-size: 1.5rem;
    background: linear-gradient(135deg, #FB6200, #FB6200);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #cbd5e1;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    padding: 12px 16px;
    border-radius: 12px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.nav-link:hover::before {
    left: 100%;
}

.nav-link:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.nav-icon {
    font-size: 1.1rem;
    opacity: 0.9;
}

.nav-text {
    display: inline;
}


/* Мобильное меню */

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    gap: 4px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle span {
    width: 24px;
    height: 3px;
    background: #e2e8f0;
    border-radius: 2px;
    transition: all 0.3s ease;
    transform-origin: center;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}


/* Заголовки */

h1 {
    font-size: 3rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 24px;
    letter-spacing: -0.025em;
}

h2 {
    font-size: 2rem;
    margin-top: 40px;
    margin-bottom: 20px;
    color: #334155;
    font-weight: 600;
    letter-spacing: -0.02em;
}

h3 {
    font-size: 1.5rem;
    margin-top: 32px;
    margin-bottom: 16px;
    color: #475569;
    font-weight: 600;
}


/* Текст */

p {
    font-size: 1.125rem;
    line-height: 1.7;
    margin-bottom: 20px;
    color: #475569;
}

ul,
ol {
    font-size: 1.125rem;
    margin: 16px 0 16px 24px;
    color: #64748b;
}


/* Ссылки */

a {
    color: #8b5cf6;
    text-decoration: none;
    transition: all 0.3s ease;
}

a:hover {
    color: #7c3aed;
    text-decoration: underline;
}


/* Карточки курсов */

.courses {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 32px;
    margin-top: 40px;
}

.course-card {
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.course-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #FB6200, #FB6200, #FB6200);
    border-radius: 20px 20px 0 0;
}

.course-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
    border-color: rgba(251, 98, 0, 0.3);
}

.course-card h2 {
    font-size: 1.5rem;
    margin: 0;
    color: #1e293b;
}

.course-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 16px;
}

.course-status {
    font-size: 0.85rem;
    font-weight: 600;
    color: #FB6200;
    background: rgba(251, 98, 0, 0.12);
    padding: 6px 12px;
    border-radius: 999px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    white-space: nowrap;
}

.course-card p {
    margin: 0 0 24px 0;
    flex-grow: 1;
    color: #64748b;
}

.course-card .progress-container {
    margin: 0;
}


/* Прогресс */

.progress-container {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
    gap: 12px;
}

.progress-bar {
    background: rgba(148, 163, 184, 0.2);
    border-radius: 12px;
    height: 8px;
    width: 100%;
    overflow: hidden;
    position: relative;
}

.progress {
    background: linear-gradient(90deg, #10b981, #34d399);
    height: 100%;
    width: 0%;
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 12px;
}

.progress-value {
    font-weight: 600;
    color: #475569;
    font-size: 0.875rem;
    min-width: 40px;
}


/* Сообщения об ошибках и уведомления */

.error {
    color: #ef4444;
    margin-bottom: 16px;
    padding: 12px 16px;
    background: rgba(239, 68, 68, 0.1);
    border-radius: 12px;
    border-left: 4px solid #ef4444;
}

.flash {
    background: rgba(34, 197, 94, 0.1);
    color: #166534;
    padding: 16px 20px;
    margin-bottom: 24px;
    border: 1px solid rgba(34, 197, 94, 0.2);
    border-radius: 16px;
    backdrop-filter: blur(10px);
}


/* Форма заданий */

.task {
    margin-bottom: 40px;
    padding: 32px;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(10px);
}

.task p {
    margin-bottom: 16px;
    color: #64748b;
}

.task form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.task label {
    margin-bottom: 8px;
    font-weight: 600;
    color: #475569;
}

.task input[type="text"] {
    padding: 16px;
    font-size: 1rem;
    border: 2px solid rgba(148, 163, 184, 0.2);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
    font-family: inherit;
}

.task input[type="text"]:focus {
    outline: none;
    border-color: #FB6200;
    background: white;
    box-shadow: 0 0 0 3px rgba(251, 98, 0, 0.1);
}

.task button,
.btn.primary {
    padding: 16px 24px;
    background: linear-gradient(135deg, #FB6200, #FB6200);
    color: white;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
}

.task button:hover,
.btn.primary:hover {
    background: linear-gradient(135deg, #FB6200, #FB6200);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(251, 98, 0, 0.3);
}

.btn.ghost {
    padding: 16px 24px;
    border-radius: 12px;
    border: 2px solid rgba(50, 110, 137, 0.15);
    color: #0f172a;
    font-weight: 600;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
}

.btn.ghost:hover {
    background: rgba(50, 110, 137, 0.04);
    transform: translateY(-2px);
}


/* Навигация по разделам */

.section-navigation {
    display: flex;
    justify-content: space-between;
    margin: 48px 0 32px 0;
    gap: 16px;
}

.section-navigation a {
    background: linear-gradient(135deg, #FB6200, #FB6200);
    color: white;
    padding: 16px 24px;
    text-decoration: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 16px rgba(251, 98, 0, 0.2);
}

.section-navigation a:hover {
    background: linear-gradient(135deg, #FB6200, #FB6200);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(251, 98, 0, 0.3);
}


/* Страница 404 */

.error-page {
    text-align: center;
    padding: 120px 20px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 24px;
    margin: 40px auto;
    max-width: 600px;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    position: relative;
    overflow: hidden;
}

.error-page h1 {
    font-size: 3rem;
    color: #FB6200;
    margin-bottom: 12px;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.error-page p {
    font-size: 1.125rem;
    color: #64748b;
    margin: 8px 0 24px 0;
    padding: 0;
}

.error-badge {
    display: inline-block;
    padding: 6px 12px;
    font-size: 0.8125rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #fff;
    background: linear-gradient(135deg, #326E89, #326E89);
    border-radius: 999px;
    margin-bottom: 12px;
}

.error-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.error-page .btn.primary,
.error-page .btn.primary:hover {
    background: linear-gradient(135deg, #FB6200, #FB6200);
}

.error-page .btn.ghost {
    border-color: rgba(50, 110, 137, 0.25);
}

.error-illustration {
    position: absolute;
    inset: -20% -10% auto -10%;
    height: 240px;
    background: radial-gradient(220px 120px at 15% 40%, rgba(50, 110, 137, 0.18), transparent 60%), radial-gradient(180px 100px at 85% 30%, rgba(251, 98, 0, 0.15), transparent 60%), radial-gradient(260px 140px at 50% -10%, rgba(50, 110, 137, 0.12), transparent 60%);
    filter: blur(10px);
    pointer-events: none;
}

@media (max-width: 600px) {
    .error-page {
        padding: 72px 16px;
    }
    .error-page h1 {
        font-size: 2rem;
    }
    .error-actions {
        flex-direction: column;
    }
    .error-actions .btn {
        width: 100%;
    }
}


/* Контент курса */

.course-content {
    background: rgba(255, 255, 255, 0.9);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(10px);
    margin-top: 32px;
}

.course-content img {
    max-width: 100%;
    height: auto;
    margin: 24px 0;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.course-content h2,
.course-content h3,
.course-content h4 {
    margin-top: 40px;
    color: #334155;
}

.course-content p {
    margin-bottom: 24px;
    color: #64748b;
}

.course-content strong {
    font-weight: 600;
    color: #475569;
}

.course-content em {
    font-style: italic;
    color: #FB6200;
}

.course-content ul,
.course-content ol {
    margin-left: 24px;
    margin-bottom: 24px;
    color: #64748b;
}


/* Формы входа и регистрации */

form {
    max-width: 400px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.9);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(10px);
}

form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #475569;
}

form input[type="text"],
form input[type="password"],
form select {
    width: 100%;
    padding: 16px;
    font-size: 1rem;
    margin-bottom: 20px;
    border: 2px solid rgba(148, 163, 184, 0.2);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
    font-family: inherit;
    box-sizing: border-box;
}

form input[type="text"]:focus,
form input[type="password"]:focus,
form select:focus {
    outline: none;
    border-color: #FB6200;
    background: white;
    box-shadow: 0 0 0 3px rgba(251, 98, 0, 0.1);
}

form button {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #22c55e, #4ade80);
    color: white;
    font-size: 1.125rem;
    font-weight: 600;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
    box-shadow: 0 4px 16px rgba(34, 197, 94, 0.2);
}

form button:hover {
    background: linear-gradient(135deg, #16a34a, #22c55e);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(34, 197, 94, 0.3);
}


/* Дополнительные стили */

.highlight-text {
    background: rgba(251, 98, 0, 0.05);
    border-left: 4px solid #FB6200;
    padding: 20px;
    margin: 24px 0;
    border-radius: 0 12px 12px 0;
}

.code-block {
    background: rgba(50, 110, 137, 0.05);
    border-radius: 12px;
    padding: 20px;
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
    overflow-x: auto;
    border: 1px solid rgba(148, 163, 184, 0.2);
    font-size: 0.875rem;
    line-height: 1.6;
}

footer {
    background: #326E89;
    color: rgba(255, 255, 255, 0.85);
    padding: 40px 20px;
    text-align: center;
    margin-top: 80px;
    backdrop-filter: blur(10px);
}


/* Hero section */

.hero {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 32px;
    align-items: center;
    background: radial-gradient(1200px 400px at -10% 0%, #e2e8f0 0%, rgba(226, 232, 240, 0) 60%), radial-gradient(1000px 600px at 120% 100%, #fb600050 0%, rgba(251, 98, 0, 0) 60%);
    border-radius: 28px;
    padding: 56px 48px;
    margin: 24px 0 8px;
    box-shadow: 0 20px 60px rgba(2, 6, 23, 0.08);
}

.hero-content p {
    max-width: 60ch;
}

.hero-actions {
    display: flex;
    gap: 12px;
    margin-top: 8px;
}

.hero-art {
    height: 220px;
    border-radius: 20px;
    background: linear-gradient(135deg, #0ea5e9, #22d3ee);
    opacity: .2;
}


/* Profile styles */

.profile-container {
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
}

.profile-header {
    text-align: center;
    margin-bottom: 32px;
}

.profile-card {
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(10px);
}

.profile-info {
    margin-bottom: 32px;
}

.info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
    border-bottom: 1px solid rgba(148, 163, 184, 0.1);
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    font-weight: 600;
    color: #475569;
    font-size: 1rem;
}

.info-value {
    color: #64748b;
    font-size: 1rem;
    text-align: right;
    flex: 1;
    margin-left: 16px;
}

.profile-actions {
    text-align: center;
}

.profile-form {
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(10px);
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #475569;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 16px;
    font-size: 1rem;
    border: 2px solid rgba(148, 163, 184, 0.2);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
    font-family: inherit;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #FB6200;
    background: white;
    box-shadow: 0 0 0 3px rgba(251, 98, 0, 0.1);
}

.form-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    margin-top: 32px;
}

.form-actions .btn {
    min-width: 160px;
}


/* Адаптивность */

@media (max-width: 1024px) {
    .hero {
        grid-template-columns: 1fr;
        text-align: center;
        padding: 48px 32px;
    }
    .hero-actions {
        justify-content: center;
        flex-wrap: wrap;
    }
    .nav-container {
        padding: 0 16px;
    }
}

@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: flex;
    }
    .nav-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: linear-gradient(135deg, #326E89 0%, #326E89 100%);
        flex-direction: column;
        padding: 20px;
        gap: 0;
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        box-shadow: 0 10px 30px rgba(50, 110, 137, 0.3);
    }
    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }
    .nav-link {
        width: 100%;
        justify-content: center;
        padding: 16px;
        border-radius: 12px;
        margin-bottom: 8px;
    }
    .nav-text {
        display: inline;
    }
    .courses {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    .course-card {
        padding: 24px;
    }
    .course-header {
        align-items: flex-start;
        gap: 8px;
    }
    .course-status {
        padding: 6px 10px;
    }
    .section-navigation {
        flex-direction: column;
    }
    .container {
        width: 95%;
        padding: 16px;
    }
    h1 {
        font-size: 2rem;
    }
    h2 {
        font-size: 1.5rem;
    }
    .course-content {
        padding: 24px;
    }
    form {
        padding: 24px;
        margin: 0 16px;
    }
    .hero {
        padding: 32px 24px;
        margin: 16px 0 8px;
    }
    .hero h1 {
        font-size: 2.2rem;
    }
    .hero-actions {
        flex-direction: column;
        align-items: center;
    }
    .btn {
        width: 100%;
        max-width: 280px;
        text-align: center;
    }
    .profile-container {
        padding: 16px;
    }
    .profile-card,
    .profile-form {
        padding: 24px;
    }
    .form-actions {
        flex-direction: column;
        align-items: center;
    }
    .form-actions .btn {
        width: 100%;
        max-width: 280px;
    }
}

@media (max-width: 480px) {
    .nav-container {
        padding: 0 12px;
    }
    .brand span {
        display: inline;
    }
    .container {
        width: 100%;
        padding: 12px;
    }
    .hero {
        padding: 24px 16px;
        border-radius: 20px;
    }
    .hero h1 {
        font-size: 1.8rem;
    }
    .hero p {
        font-size: 1rem;
    }
    .profile-container {
        padding: 12px;
    }
    .profile-card,
    .profile-form {
        padding: 20px;
        border-radius: 16px;
    }
    .info-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    .info-value {
        text-align: left;
        margin-left: 0;
    }
    .course-card {
        padding: 20px;
        border-radius: 16px;
    }
    .course-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    .course-status {
        align-self: flex-start;
        font-size: 0.75rem;
        letter-spacing: 0.04em;
    }
    .task {
        padding: 24px 20px;
    }
    .section-navigation a {
        padding: 14px 20px;
        font-size: 0.95rem;
    }
}


/* --- Landing Page Styles --- */

.landing-body {
    font-family: 'Segoe UI', Arial, sans-serif;
    background: #f7f7f7;
    margin: 0;
    padding: 0;
}

.banner {
    background: linear-gradient(120deg, #4f8cff 0%, #6ee7b7 100%);
    color: #fff;
    text-align: center;
    padding: 60px 20px 40px 20px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.07);
}

.banner h1 {
    font-size: 2.8em;
    margin-bottom: 0.3em;
}

.banner p {
    font-size: 1.3em;
    margin-bottom: 1.5em;
}

.cta-btn {
    background: #fff;
    color: #4f8cff;
    border: none;
    border-radius: 30px;
    padding: 15px 40px;
    font-size: 1.2em;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: background 0.2s, color 0.2s;
}

.cta-btn:hover {
    background: #4f8cff;
    color: #fff;
}

.authors {
    background: #fff;
    margin: 40px auto 0 auto;
    max-width: 900px;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    padding: 30px 20px;
    text-align: center;
}

.authors-list {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 20px;
}

.author {
    background: #e0e7ff;
    color: #3730a3;
    padding: 12px 28px;
    border-radius: 20px;
    font-size: 1.1em;
    font-weight: 500;
}

.top-courses {
    margin: 40px auto 0 auto;
    max-width: 1100px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    padding: 30px 20px;
    text-align: center;
}

.courses-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 25px;
    margin-top: 20px;
}

.course-card {
    background: #f1f5f9;
    color: #0f172a;
    border-radius: 14px;
    padding: 18px 36px;
    font-size: 1.1em;
    font-weight: 500;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.03);
    transition: background 0.2s;
}

.course-card:hover {
    background: #bae6fd;
}

.landing-footer {
    text-align: center;
    margin: 60px 0 20px 0;
    font-size: 1.3em;
    color: #4f8cff;
    font-weight: bold;
    letter-spacing: 1px;
}


/* --- Author Cards Carousel --- */

.authors-carousel {
    display: flex;
    gap: 32px;
    overflow-x: auto;
    padding: 20px 0 10px 0;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    justify-content: center;
}

.author-card {
    background: #fff;
    border: 2px solid #4f8cff33;
    border-radius: 22px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.07);
    min-width: 260px;
    max-width: 300px;
    flex: 0 0 260px;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 24px 18px 18px 18px;
    scroll-snap-align: start;
    transition: box-shadow 0.2s, border 0.2s;
}

.author-card:hover {
    box-shadow: 0 4px 24px rgba(79, 140, 255, 0.13);
    border: 2px solid #4f8cff;
}

.author-card img {
    width: 90px;
    height: 90px;
    object-fit: cover;
    border-radius: 50%;
    border: 3px solid #bae6fd;
    margin-bottom: 16px;
}

.author-name {
    font-size: 1.15em;
    font-weight: bold;
    margin-bottom: 8px;
    color: #22223b;
}

.author-desc {
    font-size: 1em;
    color: #64748b;
    margin-bottom: 0;
    text-align: center;
}

.about-authors-link {
    display: none;
    margin-top: 18px;
    font-size: 1.1em;
    color: #4f8cff;
    text-decoration: underline;
    cursor: pointer;
}


/* --- Адаптивность для author-card --- */

@media (max-width: 1200px) {
    .authors-carousel {
        gap: 24px;
    }
    .author-card {
        min-width: 220px;
        max-width: 250px;
        flex: 0 0 220px;
    }
}

@media (max-width: 900px) {
    .authors-carousel {
        gap: 18px;
    }
    .author-card {
        min-width: 180px;
        max-width: 200px;
        flex: 0 0 180px;
    }
}

@media (max-width: 700px) {
    .authors-carousel {
        gap: 12px;
    }
    .author-card {
        min-width: 90vw;
        max-width: 95vw;
        flex: 0 0 90vw;
    }
}

@media (max-width: 500px) {
    .authors-carousel {
        display: none;
    }
    .about-authors-link {
        display: block;
    }
}


/* --- Authors Page Grid --- */

.authors-page {
    max-width: 1100px;
    margin: 0 auto;
    padding: 40px 16px 60px 16px;
}

.authors-page h1 {
    text-align: center;
    margin-bottom: 36px;
    color: #22223b;
    font-size: 2.2em;
}

.authors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 32px;
    justify-items: center;
}

.authors-grid .author-card {
    min-width: 0;
    max-width: 320px;
    width: 100%;
    margin: 0;
}

@media (max-width: 700px) {
    .authors-page {
        padding: 20px 4vw 40px 4vw;
    }
    .authors-grid {
        gap: 18px;
    }
}