/* ===== LOGIN STYLES ===== */
/* Extracted from: templates\shared\login.html */

/* Hide CSRF token from being visible */
input[name="csrf_token"] {
    display: none !important;
    visibility: hidden !important;
    position: absolute !important;
    left: -9999px !important;
}

/* Hide any plain text CSRF tokens that might appear */
body * {
    font-family: inherit;
}

/* Additional protection against visible CSRF tokens */
[style*="display: none"] {
    display: none !important;
}

/* Hide any text that looks like a CSRF token */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.01);
    z-index: 9999;
    pointer-events: none;
}

/* Hide any visible CSRF tokens that might appear as text */
body *:not(input):not(script):not(style) {
    font-family: inherit;
}

/* Additional CSS to hide any stray text that might be CSRF tokens */
.login-container * {
    position: relative;
    z-index: 1;
}

/* Modern Login Page Styles */
body {
    background: transparent;
    min-height: 100vh;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    overflow: hidden;
    max-width: 450px;
    width: 100%;
    animation: slideUp 0.6s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-header {
    background: linear-gradient(135deg, #2E8B57 0%, #228B22 50%, #556B2F 100%);
    color: white;
    padding: 40px 40px 30px;
    text-align: center;
    position: relative;
}

.login-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="white" opacity="0.1"/><circle cx="75" cy="75" r="1" fill="white" opacity="0.1"/><circle cx="50" cy="10" r="0.5" fill="white" opacity="0.1"/><circle cx="10" cy="60" r="0.5" fill="white" opacity="0.1"/><circle cx="90" cy="40" r="0.5" fill="white" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.3;
}

.login-title {
    font-size: 2rem;
    font-weight: 700;
    margin: 0;
    position: relative;
    z-index: 1;
}

.login-subtitle {
    font-size: 0.95rem;
    opacity: 0.9;
    margin: 8px 0 0;
    position: relative;
    z-index: 1;
}

.login-body {
    padding: 40px;
}

.form-group {
    margin-bottom: 24px;
}

.form-label {
    font-weight: 600;
    color: #374151;
    margin-bottom: 8px;
    font-size: 0.9rem;
}

.form-control {
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    padding: 14px 16px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #fafafa;
}

.form-control:focus {
    border-color: #2E8B57;
    box-shadow: 0 0 0 3px rgba(46, 139, 87, 0.1);
    background: white;
    transform: translateY(-1px);
}

.form-control::placeholder {
    color: #9ca3af;
}

.input-group {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #6b7280;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.password-toggle:hover {
    color: #374151;
    background: #f3f4f6;
}

.form-text {
    font-size: 0.8rem;
    color: #6b7280;
    margin-top: 6px;
}

.btn-login {
    background: linear-gradient(135deg, #2E8B57 0%, #228B22 50%, #556B2F 100%);
    border: none;
    border-radius: 12px;
    padding: 16px;
    font-size: 1rem;
    font-weight: 600;
    color: white;
    width: 100%;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-login::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-login:hover::before {
    left: 100%;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(46, 139, 87, 0.3);
}

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

.security-badge {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 20px;
}

.security-features {
    background: #f8fafc;
    border-radius: 12px;
    padding: 20px;
    margin-top: 24px;
    border-left: 4px solid #10b981;
}

.security-features h6 {
    color: #374151;
    font-weight: 600;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.security-features ul {
    margin: 0;
    padding-left: 20px;
    color: #6b7280;
    font-size: 0.9rem;
}

.security-features li {
    margin-bottom: 6px;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .login-container {
        padding: 10px;
    }
    
    .login-card {
        border-radius: 20px;
    }
    
    .login-header {
        padding: 30px 30px 20px;
    }
    
    .login-title {
        font-size: 1.75rem;
    }
    
    .login-body {
        padding: 30px;
    }
}

/* Loading animation */
.btn-login.loading {
    pointer-events: none;
    opacity: 0.7;
}

.btn-login.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid transparent;
    border-top: 2px solid #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Login Divider */
.login-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 24px 0;
    color: #9ca3af;
    font-size: 0.875rem;
    font-weight: 500;
}

.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid #e5e7eb;
}

.login-divider span {
    padding: 0 16px;
    background: rgba(255, 255, 255, 0.95);
    position: relative;
    z-index: 1;
}

/* Google Sign-In Button */
.btn-google {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding: 14px 16px;
    background: white;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    color: #374151;
    text-decoration: none;
    transition: all 0.3s ease;
    margin-bottom: 20px;
}

.btn-google:hover {
    background: #f9fafb;
    border-color: #d1d5db;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    color: #1f2937;
    text-decoration: none;
}

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

.google-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

/* Loading state for Google button */
.btn-google.loading {
    pointer-events: none;
    opacity: 0.7;
}