﻿/* ==========================================================================
   EGT System Tema - Login Page CSS
   ========================================================================== */

.egt-login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #0f172a;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    padding: 2rem;
}

.egt-login-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.85);
    z-index: 1;
}

.egt-login-container {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 440px;
}

.egt-login-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 1.25rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.egt-login-header {
    padding: 2rem 2rem 0;
    text-align: center;
}

.egt-login-logo {
    max-height: 60px;
    width: auto;
    margin-bottom: 1.25rem;
}

.egt-login-header h2 {
    font-size: 1.375rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.375rem;
}

.egt-login-header p {
    color: #64748b;
    font-size: 0.875rem;
}

.egt-login-body {
    padding: 1.75rem 2rem 2rem;
}

.egt-login-form .form-group {
    margin-bottom: 1.25rem;
}

.egt-login-form label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.egt-login-form .input-group {
    position: relative;
}

.egt-login-form .input-group .input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 0.9375rem;
    z-index: 2;
}

.egt-login-form .form-control {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 2.75rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 0.625rem;
    font-size: 0.9375rem;
    color: #1e293b;
    background: #f8fafc;
    transition: all 0.2s ease;
    outline: none;
}

.egt-login-form .form-control:focus {
    border-color: var(--egt-primary-color, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
    background: #fff;
}

.egt-login-form .form-control::placeholder {
    color: #cbd5e1;
}

.egt-login-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}

.egt-remember-me {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    color: #64748b;
    cursor: pointer;
}

.egt-remember-me input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--egt-primary-color, #2563eb);
    cursor: pointer;
}

.egt-forgot-password {
    font-size: 0.8125rem;
    color: var(--egt-primary-color, #2563eb);
    text-decoration: none;
    font-weight: 500;
}

.egt-forgot-password:hover {
    text-decoration: underline;
    color: var(--egt-primary-hover, #1d4ed8);
}

.egt-login-btn {
    width: 100%;
    padding: 0.875rem;
    background: var(--egt-button-color, #2563eb);
    color: var(--egt-button-text-color, #fff);
    border: none;
    border-radius: 0.625rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.egt-login-btn:hover {
    background: var(--egt-button-hover, #1d4ed8);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4);
}

.egt-login-btn:active {
    transform: translateY(0);
}

.egt-login-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.egt-login-btn .fa-spinner {
    animation: egtSpin 0.8s linear infinite;
}

@keyframes egtSpin {
    to { transform: rotate(360deg); }
}

/* Error & Success Messages */
.egt-login-message {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1.25rem;
    font-size: 0.8125rem;
    font-weight: 500;
    display: none;
}

.egt-login-message.error {
    display: block;
    background: rgba(239, 68, 68, 0.08);
    color: #dc2626;
    border-left: 3px solid #dc2626;
}

.egt-login-message.success {
    display: block;
    background: rgba(34, 197, 94, 0.08);
    color: #16a34a;
    border-left: 3px solid #16a34a;
}

/* Login Footer */
.egt-login-footer {
    text-align: center;
    margin-top: 1.5rem;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.8125rem;
}

.egt-login-footer p {
    margin-bottom: 0.5rem;
}

.egt-login-footer .egt-login-footer-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.egt-login-footer a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 0.8125rem;
}

.egt-login-footer a:hover {
    color: #fff;
    text-decoration: underline;
}

/* Company Info on Login */
.egt-login-company-info {
    padding: 1.25rem 2rem;
    background: rgba(248, 250, 252, 0.5);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    text-align: center;
}

.egt-login-company-info h4 {
    font-size: 0.9375rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.egt-login-company-info p {
    font-size: 0.8125rem;
    color: #64748b;
    margin-bottom: 0.25rem;
}

.egt-login-company-info .egt-company-contact {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-top: 0.5rem;
    font-size: 0.75rem;
    color: #94a3b8;
}

.egt-login-company-info .egt-company-contact i {
    margin-right: 0.375rem;
    color: var(--egt-primary-color, #2563eb);
}

/* Accessibility */
.egt-login-form .form-control:focus-visible {
    outline: 2px solid var(--egt-primary-color, #2563eb);
    outline-offset: 2px;
}

/* CAPTCHA */
.egt-captcha-group {
    margin-bottom: 1.25rem;
}

.egt-captcha-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.egt-captcha-question {
    font-size: 1.125rem;
    font-weight: 700;
    color: #1e293b;
    padding: 0.625rem 0.875rem;
    background: #f1f5f9;
    border-radius: 0.5rem;
    white-space: nowrap;
    border: 1.5px solid #e2e8f0;
    letter-spacing: 1px;
    user-select: none;
}

.egt-captcha-input {
    width: 70px !important;
    padding: 0.75rem !important;
    text-align: center;
    font-size: 1.125rem !important;
    font-weight: 700;
}

.egt-captcha-refresh {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 0.5rem;
    background: #f1f5f9;
    border: 1.5px solid #e2e8f0;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.egt-captcha-refresh:hover {
    background: #e2e8f0;
    color: #334155;
}

body.egt-dark-mode .egt-captcha-question {
    background: #1e293b;
    border-color: #374151;
    color: #f1f5f9;
}

body.egt-dark-mode .egt-captcha-refresh {
    background: #1e293b;
    border-color: #374151;
    color: #94a3b8;
}

body.egt-dark-mode .egt-captcha-refresh:hover {
    background: #374151;
    color: #e2e8f0;
}

/* 2FA Step */
.egt-2fa-step {
    text-align: center;
    padding-top: 0.5rem;
}

.egt-2fa-header {
    margin-bottom: 1.5rem;
}

.egt-2fa-header i {
    font-size: 2.5rem;
    color: var(--egt-primary-color, #2563eb);
    margin-bottom: 0.75rem;
    display: block;
}

.egt-2fa-header h4 {
    font-size: 1.125rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.375rem;
}

.egt-2fa-header p {
    font-size: 0.8125rem;
    color: #64748b;
    margin: 0;
}

.egt-2fa-input-row {
    margin-bottom: 1.25rem;
}

.egt-2fa-input {
    width: 180px;
    padding: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 0.75rem;
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: 0.5em;
    text-align: center;
    color: #1e293b;
    background: #f8fafc;
    outline: none;
    transition: all 0.2s ease;
    font-family: 'Courier New', monospace;
}

.egt-2fa-input:focus {
    border-color: var(--egt-primary-color, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
    background: #fff;
}

.egt-2fa-input::placeholder {
    color: #cbd5e1;
    letter-spacing: 0.3em;
}

.egt-2fa-back {
    display: block;
    margin: 0.75rem auto 0;
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 0.8125rem;
    cursor: pointer;
    text-decoration: underline;
    transition: color 0.2s ease;
}

.egt-2fa-back:hover {
    color: #64748b;
}

body.egt-dark-mode .egt-2fa-header h4 {
    color: #f1f5f9;
}

body.egt-dark-mode .egt-2fa-header p {
    color: #94a3b8;
}

body.egt-dark-mode .egt-2fa-input {
    background: #1e293b;
    border-color: #374151;
    color: #f1f5f9;
}

body.egt-dark-mode .egt-2fa-input:focus {
    border-color: var(--egt-primary-color, #2563eb);
    background: #0f172a;
}

/* Social Login / Yandex */
.egt-social-login {
    margin-top: 1.25rem;
}

.egt-social-divider {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.egt-social-divider::before,
.egt-social-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e2e8f0;
}

.egt-social-divider span {
    font-size: 0.8125rem;
    color: #94a3b8;
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.egt-btn-yandex {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.625rem;
    width: 100%;
    padding: 0.75rem 1rem;
    background: #fc0;
    color: #333;
    border: none;
    border-radius: 0.625rem;
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.egt-btn-yandex:hover {
    background: #fbbd00;
    color: #000;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(252, 204, 0, 0.4);
}

.egt-btn-yandex:active {
    transform: translateY(0);
}

body.egt-dark-mode .egt-btn-yandex {
    background: #d4a800;
    color: #1e293b;
}

body.egt-dark-mode .egt-btn-yandex:hover {
    background: #fc0;
}

body.egt-dark-mode .egt-social-divider::before,
body.egt-dark-mode .egt-social-divider::after {
    background: #374151;
}

body.egt-dark-mode .egt-social-divider span {
    color: #64748b;
}

/* Google reCAPTCHA / Turnstile */
.g-recaptcha,
.cf-turnstile {
    margin: 0.25rem 0;
}

/* Back to home link */
.egt-back-home {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.8125rem;
    margin-bottom: 1rem;
}

.egt-back-home:hover {
    color: #fff;
}
