/* CSS переменные для совместимости */
:root {
    --primary-bg: rgba(255, 255, 255, 0.1);
    --glass-blur: blur(20px);
    --glass-border: 1px solid rgba(255, 255, 255, 0.2);
    --card-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.8);
    --accent-color: #7c4dff;
}

/* Стили для попапа */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.popup-overlay.active {
    display: flex;
}

.auth-popup {
    background: var(--primary-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: var(--glass-border);
    border-radius: 20px;
    padding: 2rem;
    width: 90%;
    max-width: 400px;
    position: relative;
    box-shadow: var(--card-shadow);
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.3s ease;
}

.popup-overlay.active .auth-popup {
    transform: translateY(0);
    opacity: 1;
}

.popup-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.popup-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.auth-popup h2 {
    color: var(--text-primary);
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.auth-input-group {
    width: 100%;
    margin-bottom: 1rem;
}

.auth-checkbox-group {
    width: 100%;
    margin-bottom: 1rem;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}

.auth-checkbox {
    appearance: none;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.05);
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
    flex-shrink: 0;
    margin-top: 2px;
}

.auth-checkbox:checked {
    background: var(--accent-color);
    border-color: var(--accent-color);
}

.auth-checkbox:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 12px;
    font-weight: bold;
}

.auth-checkbox:hover {
    border-color: rgba(255, 255, 255, 0.5);
}

.auth-checkbox-label {
    color: var(--text-secondary);
    font-size: 0.85rem;
    line-height: 1.4;
    cursor: pointer;
    user-select: none;
}

.privacy-link {
    color: var(--accent-color);
    text-decoration: none;
    transition: all 0.3s ease;
}

.privacy-link:hover {
    text-decoration: underline;
    color: rgba(124, 77, 255, 0.8);
}

.auth-input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: var(--glass-border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.auth-input:focus {
    outline: none;
    border-color: var(--accent-color);
    background: rgba(255, 255, 255, 0.1);
}

.auth-input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.auth-submit, .auth-back {
    width: 100%;
    padding: 12px;
    background: rgba(124, 77, 255, 0.2);
    border: var(--glass-border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 1rem;
}

.auth-submit:hover, .auth-back:hover {
    background: rgba(124, 77, 255, 0.3);
    transform: translateY(-2px);
}

.auth-back {
    background: rgba(255, 255, 255, 0.1);
    margin-top: 0.5rem;
}

.auth-back:hover {
    background: rgba(255, 255, 255, 0.2);
}

.auth-error {
    color: #ff6b6b;
    font-size: 0.85rem;
    margin-top: 0.5rem;
    text-align: center;
}

.verify-text {
    color: var(--text-secondary);
    text-align: center;
    margin-bottom: 1rem;
    font-size: 0.9rem;
}

.auth-form {
    width: 100%;
} 