/* ==========================================================================
   LANDING PAGE: AUTH MODALS (Shared Styles)
   ========================================================================== */

/* --- Переопределение анимации: Выезд сверху на мобилке --- */
.auth-modal-style.modal-overlay {
    align-items: flex-start; /* Прижимаем к верху экрана */
}

.auth-modal-style .modal-sheet {
    width: 100%;
    max-width: 600px;
    transform: translateY(-100%); /* Прячем за верхней границей экрана */
    border-radius: 0 0 var(--radius-lg) var(--radius-lg); /* Скругляем только низ */
    padding-top: 20px;
}

.auth-modal-style.modal-overlay.open .modal-sheet {
    transform: translateY(0); /* Выезжает вниз */
}

/* На десктопе возвращаем стандартное центрирование */
@media (min-width: 1024px) {
    .auth-modal-style.modal-overlay { align-items: center; }
    .auth-modal-style .modal-sheet {
        transform: translateY(20px);
        opacity: 0;
        border-radius: var(--radius-lg);
    }
    .auth-modal-style.modal-overlay.open .modal-sheet {
        transform: translateY(0);
        opacity: 1;
    }
}

/* --- Стили содержимого --- */

.modal-sheet {
    position: relative;
}

.modal-close-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    transition: color 0.2s;
}
.modal-close-btn:hover { color: var(--text-primary); }
.modal-close-btn svg { width: 24px; height: 24px; }

.auth-subtitle {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 24px;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 24px;
}

.auth-register-link {
    text-align: center;
    font-size: 14px;
    color: var(--text-secondary);
    margin-top: 8px;
}

.auth-register-link a {
    color: var(--accent);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.auth-register-link a:hover {
    color: var(--accent-hover);
    text-decoration: underline;
}

.auth-divider {
    display: flex;
    align-items: center;
    margin-bottom: 24px;
}
.auth-divider::before, .auth-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--border);
}
.auth-divider span {
    padding: 0 12px;
    font-size: 13px;
    color: var(--text-secondary);
    white-space: nowrap;
}

.auth-socials {
    display: flex;
    gap: 12px;
}

.social-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px;
    border-radius: var(--radius-sm);
    background: var(--bg-primary);
    border: 1px solid var(--border);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.social-btn:hover {
    border-color: var(--text-secondary);
    background: var(--bg-card-active);
}

.vk-btn svg { color: #0077FF; }
.tg-btn svg { color: #26A5E4; }

/* --- Спиннер загрузки виджетов --- */
.widget-loader {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 30px 0;
    color: var(--text-secondary);
    font-size: 14px;
}

.loader-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid var(--border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}