/* static/connections/css/index.css */

html {
    scroll-behavior: smooth;
}

.hero-index {
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px 20px;
    background: linear-gradient(135deg, #f5f7ff 0%, #ffffff 100%);
}

.hero-content {
    max-width: 1200px;
    width: 100%;
    text-align: center;
}

.hero-logo {
    max-width: 450px;
    height: auto;
    margin-bottom: 30px;
}

.hero-title {
    font-size: 48px;
    font-weight: 800;
    background: linear-gradient(to bottom right, #393EB4 40%, #8F39B4 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 20px;
    color: #6c757d;
    margin-bottom: 40px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-hero-primary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 32px;
    font-size: 18px;
    font-weight: 600;
    background: linear-gradient(to bottom right, #393EB4 40%, #8F39B4 100%);
    color: white;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(57, 62, 180, 0.3);
}

.btn-hero-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(57, 62, 180, 0.4);
    color: white;
    text-decoration: none;
}

.btn-hero-secondary {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 32px;
    font-size: 18px;
    font-weight: 600;
    background: transparent;
    color: #393EB4;
    border: none;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-hero-secondary:hover {
    background: rgba(57, 62, 180, 0.1);
    transform: translateY(-3px);
    color: #393EB4;
    text-decoration: none;
}

.features {
    padding: 50px 20px;
    background: #f8f9fa;
}

.features-container {
    max-width: 1200px;
    margin: 0 auto;
}

.features-title {
    text-align: center;
    font-size: 36px;
    font-weight: 700;
    color: #333;
    margin-bottom: 50px;
}

.features-title span {
    background: linear-gradient(to bottom right, #393EB4 40%, #8F39B4 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.feature-card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, rgba(57, 62, 180, 0.1) 0%, rgba(143, 57, 180, 0.1) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.feature-icon i {
    font-size: 36px;
    background: linear-gradient(to bottom right, #393EB4 40%, #8F39B4 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.feature-card h3 {
    font-size: 22px;
    font-weight: 700;
    color: #333;
    margin-bottom: 15px;
}

.feature-card p {
    font-size: 16px;
    color: #6c757d;
    line-height: 1.6;
}

.cta-section {
    padding: 80px 20px;
    background: linear-gradient(to bottom right, #393EB4 40%, #8F39B4 100%);
    text-align: center;
}

.cta-title {
    font-size: 36px;
    font-weight: 700;
    color: white;
    margin-bottom: 20px;
}

.cta-subtitle {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 35px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.btn-cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 36px;
    font-size: 18px;
    font-weight: 600;
    background: white;
    color: #393EB4;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn-cta:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    color: #393EB4;
    text-decoration: none;
}

.contact-info {
    padding: 40px 20px;
    background: #f8f9fa;
    text-align: center;
    border-top: 1px solid #e0e0e0;
}

.contact-container {
    max-width: 800px;
    margin: 0 auto;
}

.contact-text {
    font-size: 16px;
    color: #6c757d;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.contact-text i {
    color: white;
    background: linear-gradient(to bottom right, #393EB4 40%, #8F39B4 100%);
    font-size: 18px;
    width: 38px;
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(57, 62, 180, 0.3);
}

.contact-email {
    color: #393EB4;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.contact-email:hover {
    color: #8F39B4;
    text-decoration: underline;
}

/* Выделение текста с бесплатным доступом */
.free-trial-highlight {
    display: inline-block;
    background: linear-gradient(135deg, rgba(57, 62, 180, 0.12), rgba(143, 57, 180, 0.08));
    padding: 8px 20px;
    border-radius: 50px;
    font-weight: 700;
    color: #393EB4;
    margin-top: 12px;
    font-size: 18px;
    /* border-left: 2px solid #8F39B4; */
    /* border-right: 2px solid #8F39B4; */
}

/* Для авторизованного пользователя */
.free-trial-welcome {
    min-width: 400px;
    padding: 12px 28px;
    font-size: 20px;
    line-height: 1.4;
    text-align: center;
    /* border-left: 3px solid #8F39B4;
    border-right: 3px solid #8F39B4; */
}

/* Быстрый вход */
.quick-login {
    padding: 20px 20px 0;
    background: linear-gradient(135deg, #f5f7ff 0%, #ffffff 100%);
}

.quick-login-container {
    max-width: 600px;
    margin: 0 auto 30px;
}

/* Общий контейнер для формы и блока с именем */
.quick-login-form,
.quick-login-welcome {
    display: flex;
    justify-content: center;
    width: 100%;
}

/* Ряд для неавторизованного пользователя */
.quick-login-row {
    display: flex;
    gap: 12px;
    width: 100%;
    max-width: 500px;
    background: white;
    padding: 12px 16px;
    border-radius: 60px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    border: 1px solid #e8e8e8;
    transition: all 0.3s ease;
}

/* Блок для авторизованного пользователя */
.quick-login-welcome {
    width: 100%;
    max-width: 500px;
    background: white;
    padding: 12px 16px;
    border-radius: 60px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    border: 1px solid #e8e8e8;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.quick-login-row:focus-within {
    border-color: #393EB4;
    box-shadow: 0 2px 20px rgba(57, 62, 180, 0.15);
}

.quick-login-input {
    flex: 1;
    border: none;
    padding: 10px 14px;
    font-size: 15px;
    background: transparent;
    outline: none;
    color: #333;
    min-width: 0;
}

.quick-login-input::placeholder {
    color: #aaa;
}

.quick-login-btn {
    padding: 10px 24px;
    background: linear-gradient(to bottom right, #393EB4 40%, #8F39B4 100%);
    color: white;
    border: none;
    border-radius: 40px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}

.quick-login-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(57, 62, 180, 0.3);
    color: white;
    text-decoration: none;
}

.quick-login-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.quick-login-error {
    text-align: center;
    margin-top: 10px;
    font-size: 14px;
    color: #dc3545;
}

.user-name-display {
    font-size: 16px;
    font-weight: 700;
    background: linear-gradient(to bottom right, #393EB4 40%, #8F39B4 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.quick-login-buttons {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-shrink: 0;
}

.quick-logout-btn {
    padding: 10px 20px;
    background: white;
    color: #333;
    border: 1px solid #ddd;
    border-radius: 40px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.quick-logout-btn:hover {
    background: #dc3545;
    color: white;
    border-color: #dc3545;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.3);
}

/* Разделитель ИЛИ */
.login-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 12px 0;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #ddd;
}

.login-divider span {
    padding: 0 16px;
    color: #999;
    font-size: 13px;
    font-weight: 500;
}

/* Кнопки соцсетей — общий стиль для всех */
.social-login {
    display: flex;
    gap: 10px;
    max-width: 500px;
    margin: 0 auto;
}

.btn-social {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex: 1;
    padding: 10px 12px;
    background: white;
    border: 1px solid #e8e8e8;
    border-radius: 60px;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.06);
    cursor: pointer;
    white-space: nowrap;
}

.btn-social:hover {
    transform: translateY(-2px);
    color: #333;
    text-decoration: none;
}

.btn-social img {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

.btn-yandex:hover {
    border-color: #FC3F1D;
    box-shadow: 0 2px 20px rgba(252, 63, 29, 0.15);
}

.btn-vk:hover {
    border-color: #2787F5;
    box-shadow: 0 2px 20px rgba(39, 135, 245, 0.15);
}

/* Галка согласия для Яндекс ID на главной */
.terms-group-index {
    margin-top: 12px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.terms-option-index {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    cursor: pointer;
    font-weight: normal;
    font-size: 13px;
    line-height: 1.4;
    color: #333;
}

.terms-option-index input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin-top: 2px;
    cursor: pointer;
    flex-shrink: 0;
    accent-color: #393EB4;
}

.terms-option-index span {
    color: #333;
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 32px;
    }
    
    .hero-subtitle {
        font-size: 16px;
    }
    
    .features-title {
        font-size: 28px;
    }
    
    .cta-title {
        font-size: 28px;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-hero-primary,
    .btn-hero-secondary {
        width: 100%;
        max-width: 280px;
        justify-content: center;
    }

    .hero-logo {
        max-width: 240px;
    }

    .contact-text {
        font-size: 14px;
    }
    
    .contact-text i {
        width: 32px;
        height: 32px;
        font-size: 16px;
    }

    .free-trial-highlight {
        font-size: 14px;
        padding: 4px 30px;
    }

    .quick-login-row {
        flex-direction: column;
        border-radius: 16px;
        padding: 12px;
        gap: 10px;
    }
    
    .quick-login-input {
        padding: 10px 14px;
        font-size: 14px;
        border: 1px solid #eee;
        border-radius: 8px;
        background: #f8f9fa;
    }
    
    .quick-login-btn {
        width: 100%;
        padding: 12px;
        font-size: 14px;
        justify-content: center;
    }

    .quick-login-welcome {
        flex-direction: column;
        gap: 10px;
        border-radius: 16px;
        padding: 12px;
    }

    .quick-login-buttons {
        flex-direction: column;
        width: 100%;
    }

    .quick-login-btn,
    .quick-logout-btn {
        width: 100%;
        justify-content: center;
    }

    .user-name-display {
        white-space: normal;
        text-align: center;
    }

    .social-login {
        flex-direction: column;
        gap: 8px;
    }
    
    .btn-social {
        padding: 12px;
        font-size: 14px;
    }

    .free-trial-welcome {
        min-width: auto;
        width: 100%;
        padding: 8px 12px;
        font-size: 14px;
    }

}