/* assets/style.css - Единый стиль для всего сайта */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@300;400;500;600;700;800&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #e9ecf2 100%);
    min-height: 100vh;
    color: #2d3748;
    display: flex;
    flex-direction: column;
}

/* Защита от выделения */
body {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Разрешаем выделение на нужных элементах */
input, textarea, .code-number, .btn, .copy-code-btn, 
.nav-links a, .logo, .step, .footer a {
    -webkit-user-select: text !important;
    -moz-user-select: text !important;
    -ms-user-select: text !important;
    user-select: text !important;
}

/* Логотип */
.logo {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.5px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    font-family: 'Montserrat', sans-serif;
}

.logo span:first-child {
    color: #1a202c;
}

.logo span:last-child {
    background: linear-gradient(135deg, #f97316 0%, #b45309 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-left: 2px;
}

/* Навигация */
.navbar {
    background: white;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    padding: 15px 40px;
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.95);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-links a {
    color: #4a5568;
    text-decoration: none;
    font-weight: 500;
    font-size: 15px;
    transition: color 0.3s;
    position: relative;
    font-family: 'Montserrat', sans-serif;
}

.nav-links a:hover {
    color: #f97316;
}

/* Кнопки */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.3s;
    cursor: pointer;
    border: none;
    font-family: 'Montserrat', sans-serif;
}

.btn-primary {
    background: linear-gradient(135deg, #f97316 0%, #b45309 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(249, 115, 22, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(249, 115, 22, 0.4);
}

.btn-secondary {
    background: #e2e8f0;
    color: #1a202c;
}

.btn-secondary:hover {
    background: #cbd5e0;
    transform: translateY(-2px);
}

/* Контейнер для страниц входа */
.auth-container {
    max-width: 800px;
    margin: 40px auto;
    padding: 0 20px;
    flex: 1;
    width: 100%;
}

/* Приветственная секция */
.welcome-section {
    background: linear-gradient(135deg, #1a202c 0%, #2d3748 100%);
    color: white;
    border-radius: 30px;
    padding: 30px 20px;
    margin-bottom: 30px;
    text-align: center;
}

.welcome-section h1 {
    color: white;
    margin-bottom: 10px;
    font-size: clamp(22px, 5vw, 32px);
    font-weight: 700;
}

.welcome-section p {
    color: #a0aec0;
    font-size: 14px;
}

/* Карточка с кодом */
.code-card {
    background: white;
    border-radius: 20px;
    padding: 25px 20px;
    margin-bottom: 30px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.05);
    text-align: center;
}

.code-card-title {
    font-size: 16px;
    margin-bottom: 15px;
    color: #4a5568;
}

.code-box {
    background: linear-gradient(135deg, #1a202c 0%, #2d3748 100%);
    border-radius: 20px;
    padding: 25px 15px;
    text-align: center;
    margin: 15px 0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    position: relative;
    width: 100%;
}

.code-number {
    font-size: 56px;
    font-weight: 700;
    letter-spacing: 5px;
    color: white;
    font-family: 'Montserrat', monospace;
    text-shadow: 0 2px 10px rgba(249, 115, 22, 0.5);
    line-height: 1.2;
    word-break: break-all;
    overflow-wrap: break-word;
}

@media (max-width: 480px) {
    .code-number {
        font-size: 42px;
        letter-spacing: 3px;
    }
}

@media (max-width: 360px) {
    .code-number {
        font-size: 36px;
        letter-spacing: 2px;
    }
}

/* Кнопка копирования */
.copy-code-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255,255,255,0.15);
    border: none;
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: all 0.3s;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255,255,255,0.2);
    z-index: 10;
}

.copy-code-btn:hover {
    background: rgba(249,115,22,0.8);
    transform: scale(1.1);
}

.copy-code-btn.copied {
    background: #48bb78;
}

/* Таймер */
.timer {
    color: #a0aec0;
    font-size: 14px;
    margin-top: 10px;
    font-weight: 500;
}

/* Секция с действиями */
.action-section {
    background: white;
    border-radius: 20px;
    padding: 30px 20px;
    margin-bottom: 30px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.05);
}

/* Статус */
.status {
    margin: 20px 0;
    padding: 15px;
    border-radius: 10px;
    text-align: center;
    display: none;
    font-weight: 500;
    font-size: 14px;
}

.status.success {
    background: #c6f6d5;
    color: #22543d;
    display: block;
}

.status.info {
    background: #bee3f8;
    color: #2c5282;
    display: block;
}

/* Лоадер */
.loader {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #f97316;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 15px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Шаги */
.steps {
    background: #f7fafc;
    border-radius: 15px;
    padding: 20px 15px;
    margin-top: 25px;
}

.step {
    display: flex;
    align-items: center;
    margin: 10px 0;
    padding: 12px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.step-number {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, #f97316 0%, #b45309 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    margin-right: 12px;
    font-size: 16px;
    flex-shrink: 0;
}

.step div {
    font-size: 14px;
    word-break: break-word;
}

/* Информация о редиректе */
.redirect-info {
    background: #f7fafc;
    border-radius: 15px;
    padding: 15px;
    margin: 20px 0;
    border-left: 5px solid #f97316;
    word-break: break-word;
    font-size: 14px;
}

.redirect-info strong {
    color: #1a202c;
    display: block;
    margin-top: 8px;
    font-size: 13px;
    word-break: break-all;
}

/* Уведомления */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #1a202c;
    color: white;
    padding: 10px 20px;
    border-radius: 10px;
    border-left: 4px solid #f97316;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    z-index: 10000;
    animation: slideIn 0.3s ease;
    font-size: 13px;
    max-width: 90%;
    font-family: 'Montserrat', sans-serif;
}

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes slideOut {
    from { transform: translateX(0); opacity: 1; }
    to { transform: translateX(100%); opacity: 0; }
}

/* Мобильная адаптация */
@media (max-width: 768px) {
    .navbar {
        padding: 15px 20px;
    }
    
    .nav-container {
        flex-direction: column;
        gap: 15px;
    }
    
    .nav-links {
        flex-wrap: wrap;
        justify-content: center;
        gap: 15px;
    }
    
    .nav-links a {
        margin: 0;
    }
    
    .btn {
        display: block;
        width: 100%;
        margin: 8px 0;
    }
}