/* Login Container */
.login-container {
    min-height: 100vh;
    background: #1a1a1a;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

/* Login Card */
.login-cardMain,
.login-card {
    display: flex;
    width: 100%;
    max-width: 700px;
    min-height: 600px;
    background: #2a2a2a;
    border-radius: 8px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    overflow: hidden;
}

/* Left Panel */
.left-panel {
    background: #0f0f0f;
    width: 200px;
    min-width: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
}

.image-wrapper {
    position: relative;
    width: 160px;
    height: 160px;
}

.logo-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 160px;
    height: 160px;
}

/* Базовый веном - всегда виден */
.logo-image.base {
    opacity: 1;
    z-index: 1;
}

/* Глаза - поверх базы, пульсируют */
.logo-image.eyes {
    opacity: 0;
    z-index: 2;
    transition: opacity 0.8s ease-in-out;
}

.logo-image.eyes.visible {
    opacity: 1;
}

/* Right Panel */
.right-panel {
    flex: 1;
    background: #2a2a2a;
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Login Header */
.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.brand {
    font-size: 1.6rem;
    font-weight: 700;
    color: #fff;
    letter-spacing: 2px;
    margin-bottom: 0.25rem;
}

.brand-accent,
.accent {
    color: #26c6da;
}

.brand-subtitle {
    font-size: 0.75rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 1.5rem;
}

.title {
    color: #fff;
    font-size: 1.4rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

/* Login Form */
.login-form {
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-label {
    display: block;
    color: #e9ecef;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.form-label i {
    color: #26c6da;
    margin-right: 0.5rem;
}

.form-control {
    width: 100%;
    background: #1a1a1a;
    border: 1px solid #444;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    color: #fff;
    font-size: 1rem;
    transition: all 0.2s ease;
    outline: none;
}

.form-control:focus {
    color: #fff;
    background: #1a1a1a;
    border-color: #26c6da;
    box-shadow: 0 0 0 0.2rem rgba(38, 198, 218, 0.25);
}

.form-control::placeholder {
    color: #6c757d;
}

/* Form text helper */
.form-text {
    color: #6c757d;
    font-size: 0.875rem;
    margin-top: 0.25rem;
    display: block;
}

/* Автозаполнение браузера */
.form-control:-webkit-autofill,
.form-control:-webkit-autofill:hover,
.form-control:-webkit-autofill:focus,
.form-control:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px #1a1a1a inset !important;
    -webkit-text-fill-color: #fff !important;
    box-shadow: 0 0 0 1000px #1a1a1a inset !important;
    caret-color: #fff;
    transition: background-color 5000s ease-in-out 0s;
}

/* Password Input */
.password-input-container {
    position: relative;
}

.password-input-container .form-control {
    padding-right: 3rem;
}

.password-toggle {
    position: absolute;
    top: 50%;
    right: 0.75rem;
    transform: translateY(-50%);
    border: none;
    background: none;
    color: #6c757d;
    padding: 0.25rem;
    cursor: pointer;
    transition: color 0.2s ease;
    z-index: 10;
}

.password-toggle:hover,
.password-toggle:focus {
    color: #26c6da;
    outline: none;
}

/* Error Message */
.error-message {
    background: #4d1a1a;
    border: 1px solid #ef4444;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
    color: #fff;
    font-size: 0.9rem;
}

.error-message strong {
    color: #ef4444;
    margin-right: 0.5rem;
}

/* Captcha */
.captcha-container {
    margin-bottom: 1rem;
}

.captcha-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    justify-content: center;
}

.captcha-image {
    min-width: 180px;
    min-height: 60px;
    border-radius: 6px;
    overflow: hidden;
    background: #1a1a2e;
}

.captcha-image svg {
    display: block;
    vertical-align: top;
}

.captcha-refresh {
    flex-shrink: 0;
    padding: 0.5rem;
}

.checkbox-container {
    background: #1a1a1a;
    border: 1px solid #444;
    border-radius: 6px;
    padding: 0.5rem 0.75rem;
    transition: all 0.2s ease;
    width: 50%;
    margin: 0 auto;
}

.checkbox-container:focus-within {
    border-color: #26c6da;
    box-shadow: 0 0 0 0.2rem rgba(38, 198, 218, 0.25);
}

.checkbox-label {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    user-select: none;
    margin: 0;
}

.captcha-checkbox {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: relative;
    height: 16px;
    width: 16px;
    background: #2a2a2a;
    border: 2px solid #444;
    border-radius: 3px;
    margin-right: 8px;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.checkbox-label:hover .checkmark {
    border-color: #26c6da;
}

.captcha-checkbox:checked ~ .checkmark {
    background: #26c6da;
    border-color: #26c6da;
}

.captcha-checkbox:checked ~ .checkmark::after {
    content: "";
    position: absolute;
    display: block;
    left: 4px;
    top: 1px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.label-text {
    color: #e9ecef;
    font-weight: 500;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    text-transform: uppercase;
}

.label-text i {
    color: #26c6da;
    margin-right: 0.5rem;
}

/* me-2 Bootstrap spacing */
.me-2 {
    margin-right: 0.5rem !important;
}

/* Спиннер загрузки для капчи */
.captcha-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid #444;
    border-top-color: #26c6da;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-right: 8px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Скрываем чекмарк во время загрузки */
.checkbox-label.loading .checkmark {
    display: none;
}

/* Отключаем клик во время загрузки */
.checkbox-label.loading {
    pointer-events: none;
}

.checkbox-label.verified {
    pointer-events: none;
}

.checkbox-label.verified .checkmark {
    background: #26c6da;
    border-color: #26c6da;
}

.checkbox-label.verified .checkmark::after {
    content: "";
    position: absolute;
    display: block;
    left: 4px;
    top: 1px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Login Button */
.login-button {
    width: 100%;
    background: #26c6da;
    border: 1px solid #26c6da;
    border-radius: 4px;
    padding: 0.75rem 1rem;
    font-weight: 600;
    font-size: 1rem;
    color: #fff;
    cursor: pointer;
    transition: all 0.2s ease;
}

.login-button:hover:not(:disabled) {
    background: #00acc1;
    border-color: #00acc1;
}

.login-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Login Footer */
.login-footer {
    text-align: center;
    padding-top: 1rem;
    border-top: 1px solid #444;
}

.login-footer p {
    color: #6c757d;
    font-size: 0.875rem;
    margin: 0;
}

.login-footer i {
    margin-right: 0.25rem;
}

/* Test Credentials */
.test-credentials {
    margin-top: 1rem;
    padding: 1rem;
    background: #1a1a1a;
    border-radius: 8px;
    border: 1px solid #444;
    text-align: center;
    font-size: 0.875rem;
    color: #6c757d;
}

.test-credentials strong {
    color: #26c6da;
    display: block;
    margin-bottom: 0.5rem;
}

.test-credentials code {
    background: #2a2a2a;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    color: #fff;
    font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 768px) {
    .login-cardMain {
        flex-direction: column;
        max-width: 500px;
        min-height: auto;
    }
    
    .left-panel {
        width: 100%;
        min-width: 100%;
        padding: 2rem;
    }
    
    .right-panel {
        padding: 2rem;
    }
    
    .title {
        font-size: 1.5rem;
    }
}

@media (max-width: 576px) {
    .login-container {
        padding: 1rem;
    }
    
    .left-panel,
    .right-panel {
        padding: 1rem;
    }
    
    .title {
        font-size: 1.3rem;
    }
    .login-header{
        margin-bottom: 1rem;
    }
    .brand {
        font-size: 1.3rem;
    }
    .brand-subtitle {
        font-size: 0.55rem;
        margin-bottom: 1rem;
    }
    .image-wrapper {
        width: 120px;
        height: 120px;
    }
    .logo-image {
        width: 120px;
        height: 120px;
    }
    .test-credentials {
        margin-top: 0rem;
        padding: 0.5rem;
    }
    .test-credentials strong{
        margin-bottom: 0rem;
    }
    .checkbox-container{
        width: 65%;
    } 
    .login-footer{
        border-top: none;
    }
}

/* Селектор типа контакта */
.contact-type-selector {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.contact-type-option {
    flex: 1;
}

.contact-type-option input {
    display: none;
}

.contact-type-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.375rem;
    padding: 0.75rem 0.5rem;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    color: #888;
    font-size: 0.8125rem;
    cursor: pointer;
    transition: all 0.3s;
}

.contact-type-btn i {
    font-size: 1.25rem;
}

.contact-type-option input:checked + .contact-type-btn {
    background: rgba(38,198,218,0.15);
    border-color: #26c6da;
    color: #26c6da;
}

.contact-type-btn:hover {
    border-color: rgba(255,255,255,0.3);
    color: #fff;
}

/* Счётчик символов */
.char-counter {
    float: right;
    color: #666;
}

/* Регистрация */
.auth-divider {
    text-align: center;
    margin: 1.5rem 0;
    position: relative;
}

.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: rgba(255,255,255,0.1);
}

.auth-divider span {
    position: relative;
    background: #2a2a2a;
    padding: 0 1rem;
    color: #666;
    font-size: 0.875rem;
}

.btn-outline-primary {
    width: 100%;
    padding: 0.875rem;
    background: transparent;
    border: 1px solid #26c6da;
    color: #26c6da;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: all 0.3s;
}

.btn-outline-primary:hover {
    background: #26c6da;
    color: #000;
}

.btn-text {
    width: 100%;
    padding: 0.75rem;
    background: transparent;
    border: none;
    color: #888;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.btn-text:hover {
    color: #fff;
}

.message-box {
    padding: 0.875rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    font-size: 0.9375rem;
}

.message-box--error {
    background: rgba(255,68,68,0.15);
    border: 1px solid rgba(255,68,68,0.3);
    color: #ff6b6b;
}

.message-box--success {
    background: rgba(0,212,106,0.15);
    border: 1px solid rgba(0,212,106,0.3);
    color: #00d46a;
}

/* Модалка с данными */
.credentials-modal {
    border: none;
    border-radius: 16px;
    background: #1a1a1a;
    padding: 0;
    max-width: 460px;
    width: 90%;
}

.credentials-modal::backdrop {
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(4px);
}

.credentials-modal__content {
    padding: 2rem;
}

.credentials-modal__header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.credentials-modal__header i {
    font-size: 3rem;
    color: #00d46a;
    display: block;
    margin-bottom: 1rem;
}

.credentials-modal__header h3 {
    color: #fff;
    font-size: 1.5rem;
    margin: 0;
}

.credentials-modal__text {
    color: #999;
    text-align: center;
    margin-bottom: 1.5rem;
}

.credentials-box {
    background: #0d0d0d;
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 1.5rem;
}

.credential-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    border-radius: 8px;
    margin-bottom: 0.5rem;
}

.credential-row:last-child {
    margin-bottom: 0;
}

.credential-row--secret {
    background: rgba(0,212,106,0.1);
    border: 1px solid rgba(0,212,106,0.2);
}

.credential-label {
    color: #888;
    font-size: 0.875rem;
    min-width: 110px;
}

.credential-value {
    flex: 1;
    font-family: 'SF Mono', Monaco, monospace;
    color: #fff;
    font-size: 0.9375rem;
    word-break: break-all;
}

.credential-row--secret .credential-value {
    color: #00d46a;
    font-weight: 700;
}

.btn-copy {
    padding: 0.5rem;
    background: rgba(255,255,255,0.1);
    border: none;
    border-radius: 6px;
    color: #888;
    cursor: pointer;
}

.btn-copy:hover {
    background: rgba(255,255,255,0.2);
    color: #fff;
}

.btn-copy-all {
    width: 100%;
    padding: 12px;
    background: transparent;
    border: 1px solid rgba(0, 255, 200, 0.3);
    color: #00ffc8;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    margin-top: 8px;
    margin-bottom: 1rem;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-copy-all:hover {
    background: rgba(0, 255, 200, 0.1);
}

.btn-copy-all.copied {
    border-color: #00ffc8;
    background: rgba(0, 255, 200, 0.15);
}

.credentials-modal__warning {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.875rem;
    background: rgba(255,193,7,0.1);
    border: 1px solid rgba(255,193,7,0.2);
    border-radius: 8px;
    color: #ffc107;
    font-size: 0.875rem;
    margin-bottom: 1.5rem;
}

.credentials-modal .btn-primary {
    width: 100%;
    padding: 0.875rem;
    background: #26c6da;
    border: none;
    border-radius: 8px;
    color: #000;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.credentials-modal .btn-primary:hover {
    filter: brightness(1.1);
}

.go-cabinet-confirm-modal__actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
}
@media screen and (max-width: 460px) {
    .go-cabinet-confirm-modal__actions {
        flex-direction: column;
    }
}

.go-cabinet-confirm-modal__actions .btn {
    flex: 1;
    padding: 0.75rem;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.9375rem;
}

.go-cabinet-confirm-modal__actions .btn-ghost {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.25);
    color: #999;
}

.go-cabinet-confirm-modal__actions .btn-ghost:hover {
    background: rgba(255,255,255,0.08);
    color: #fff;
}

.go-cabinet-confirm-modal__actions .btn-primary {
    margin-bottom: 0;
}

/* Переключатель языка */
.language-switcher {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 100;
}

.lang-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    color: #888;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.lang-btn:hover {
    background: rgba(255,255,255,0.1);
    border-color: rgba(255,255,255,0.2);
    color: #fff;
}

.lang-btn i {
    font-size: 0.75rem;
    transition: transform 0.2s ease;
}

.lang-dropdown.hidden {
    display: none;
}

.lang-dropdown {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    min-width: 200px;
    max-height: 400px;
    overflow-y: auto;
    background: #1a1a1a;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.5);
    padding: 0.5rem 0;
    z-index: 1000;
}

.lang-dropdown button {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 0.625rem 1rem;
    background: transparent;
    border: none;
    color: #e9ecef;
    font-size: 0.875rem;
    text-align: left;
    cursor: pointer;
    transition: background 0.15s ease;
}

.lang-dropdown button:hover {
    background: rgba(38,198,218,0.1);
    color: #26c6da;
}

.lang-dropdown hr {
    margin: 0.25rem 0;
    border: none;
    border-top: 1px solid rgba(255,255,255,0.1);
}

/* Кастомная полоса прокрутки - маленькая и тёмная */
.lang-dropdown {
    scrollbar-width: thin;
    scrollbar-color: #333 #1a1a1a;
}

.lang-dropdown::-webkit-scrollbar {
    width: 6px;
}

.lang-dropdown::-webkit-scrollbar-track {
    background: #1a1a1a;
    border-radius: 3px;
}

.lang-dropdown::-webkit-scrollbar-thumb {
    background: #333;
    border-radius: 3px;
}

.lang-dropdown::-webkit-scrollbar-thumb:hover {
    background: #444;
}

/* RTL поддержка */
[dir="rtl"] .language-switcher {
    right: auto;
    left: 1rem;
}

[dir="rtl"] .lang-dropdown {
    right: auto;
    left: 0;
}

[dir="rtl"] .lang-dropdown button {
    text-align: right;
}
