/* Стили для страницы авторизации */
.login-main {
    min-height: calc(100vh - 80px - 120px); /* Высота экрана минус header и footer */
    background: linear-gradient(135deg, #0f0f23 0%, #1a1a2e 50%, #16213e 100%);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}

.login-main::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.15) 0%, transparent 50%),
                radial-gradient(circle at 40% 40%, rgba(120, 213, 255, 0.1) 0%, transparent 50%);
    animation: float 15s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translate(0px, 0px) rotate(0deg); }
    33% { transform: translate(30px, -30px) rotate(120deg); }
    66% { transform: translate(-20px, 20px) rotate(240deg); }
}

.login-container {
    width: 100%;
    max-width: 450px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 48px 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3), 
                0 8px 32px rgba(120, 119, 198, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.2);
    animation: slideInUp 0.8s ease-out;
    position: relative;
    z-index: 2;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.login-logo {
    width: 80px !important;
    height: 80px !important;
    max-width: 80px;
    max-height: 80px;
    object-fit: contain;
    border-radius: 20px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    padding: 16px;
    margin: 0 auto 24px auto;
    display: block;
    box-shadow: 0 8px 32px rgba(102, 126, 234, 0.3);
}

.login-logo-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 24px;
}

.login-header h2 {
    margin: 0 0 12px 0;
    color: #2c3e50;
    font-weight: 600;
    font-size: 1.8rem;
}

.login-header p {
    margin: 0;
    color: #7f8c8d;
    font-size: 0.95rem;
}

/* Форма входа */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.input-wrap {
    position: relative;
}

.input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.2rem;
    color: #667eea;
    z-index: 2;
}

.login-form input {
    width: 100%;
    padding: 16px 16px 16px 52px;
    border: 2px solid #e3f2fd;
    border-radius: 12px;
    font-size: 1rem;
    background: #f8faff;
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.login-form input:focus {
    border-color: #667eea;
    background: #fff;
    outline: none;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.login-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: -8px 0 8px 0;
}

.checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    color: #7f8c8d;
}

.checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #667eea;
    margin: 0;
    padding: 0;
}

.forgot-password {
    color: #667eea;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.3s;
}

.forgot-password:hover {
    color: #5a67d8;
}

.login-btn {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.4);
    position: relative;
    overflow: hidden;
}

.login-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(102, 126, 234, 0.5);
}

.login-btn:active {
    transform: translateY(0);
}

.btn-loader {
    font-size: 1.2rem;
}

/* Сообщения об ошибках и успехе */
.login-error {
    margin-top: 16px;
    text-align: center;
}

.error-message {
    background: #ffebee;
    color: #c62828;
    padding: 12px 16px;
    border-radius: 8px;
    border-left: 4px solid #f44336;
    font-size: 0.9rem;
}

.success-message {
    background: #e8f5e8;
    color: #2e7d32;
    padding: 12px 16px;
    border-radius: 8px;
    border-left: 4px solid #4caf50;
    font-size: 0.9rem;
}

.login-footer {
    margin-top: 32px;
    text-align: center;
    font-size: 0.9rem;
    color: #666;
}

.login-footer p {
    margin: 8px 0;
}

.login-footer a {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
}

.login-footer a:hover {
    text-decoration: underline;
}

/* Адаптивность */
@media (max-width: 768px) {
    .login-main {
        padding: 20px;
    }
    
    .login-container {
        padding: 32px 24px;
        max-width: 100%;
    }
    
    .login-header h2 {
        font-size: 1.6rem;
    }
    
    .login-logo {
        width: 60px;
        height: 60px;
    }
}

@media (max-width: 480px) {
    .login-main {
        padding: 15px;
    }
    
    .login-container {
        padding: 24px 20px;
    }
}

/* Стили личного кабинета */
.profile {
    padding: 48px 0;
    min-height: 80vh;
}

.profile__info {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 32px;
    padding: 24px;
    background: #fffde4;
    border-radius: 16px;
    box-shadow: 0 4px 16px 0 #ff704322;
}

.profile__avatar img {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: #fff;
    padding: 8px;
}

.profile__details {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.profile__details div {
    font-size: 1.1rem;
}

.profile__tabs {
    display: flex;
    gap: 16px;
    margin-bottom: 32px;
    align-items: center;
}

.tab-btn {
    padding: 12px 24px;
    background: #fff;
    border: 2px solid #ffe0b2;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.tab-btn.active {
    background: #ff7043;
    color: #fff;
    border-color: #ff7043;
}

.tab-btn:hover {
    border-color: #ff7043;
    transform: translateY(-2px);
}

.profile__section {
    animation: fadeIn 0.5s;
}

/* Карточки персонажей */
.characters__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
    margin-top: 24px;
}

.character__card {
    background: #fffde4;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 16px 0 #ff704322;
    transition: transform 0.3s;
}

.character__card:hover {
    transform: translateY(-4px);
}

.character__card--create {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    border: 2px dashed #ff7043;
    background: transparent;
}

.character__header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.character__avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
}

.character__info h4 {
    margin: 0 0 4px 0;
    color: #ff7043;
    font-size: 1.2rem;
}

.character__id {
    font-size: 0.9rem;
    color: #666;
}

.character__status {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-top: 4px;
}

.character__status.online {
    background: #4caf50;
    color: #fff;
}

.character__status.offline {
    background: #9e9e9e;
    color: #fff;
}

.character__stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 16px;
}

.stat {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: #fff;
    border-radius: 8px;
}

.stat__label {
    font-size: 0.9rem;
    color: #666;
}

.stat__value {
    font-weight: 600;
    color: #ff7043;
}

.character__actions {
    display: flex;
    gap: 12px;
}

.btn--small {
    padding: 8px 16px;
    font-size: 0.9rem;
}

.character__create .create__icon {
    font-size: 3rem;
    color: #ff7043;
    margin-bottom: 16px;
}

/* Таблица пополнений */
.profile__table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px 0 #ff704322;
}

.profile__table th,
.profile__table td {
    padding: 16px;
    text-align: left;
    border-bottom: 1px solid #ffe0b2;
}

.profile__table th {
    background: #ff7043;
    color: #fff;
    font-weight: 600;
}

.profile__table tr:hover {
    background: #fffde4;
}

.status {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 600;
}

.status.success {
    background: #4caf50;
    color: #fff;
}

.status.pending {
    background: #ffc107;
    color: #fff;
}

.status.failed {
    background: #f44336;
    color: #fff;
}

/* Настройки */
.settings__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.setting__group {
    background: #fffde4;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 4px 16px 0 #ff704322;
}

.setting__group h4 {
    margin: 0 0 16px 0;
    color: #ff7043;
}

.checkbox {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    cursor: pointer;
}

.checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: #ff7043;
}

@media (max-width: 768px) {
    .login-main {
        padding: 20px 16px;
        min-height: calc(100vh - 60px - 80px);
    }
    
    .login-container {
        padding: 32px 24px;
        max-width: 100%;
    }
    
    .login-logo {
        width: 64px !important;
        height: 64px !important;
        max-width: 64px;
        max-height: 64px;
        padding: 12px;
    }
    
    .login-header h2 {
        font-size: 1.5rem;
    }
    
    .profile__tabs {
        flex-direction: column;
        align-items: stretch;
    }
    
    .characters__grid {
        grid-template-columns: 1fr;
    }
    
    .character__stats {
        grid-template-columns: 1fr;
    }
}
