/* Custom premium login page styling */
.auth-box {
    max-width: 580px !important;
    width: 90% !important;
    border-radius: 20px !important;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.12), 0 8px 20px rgba(0, 0, 0, 0.06) !important;
    border: 1px solid rgba(255, 255, 255, 0.85) !important;
    background: rgba(255, 255, 255, 0.98) !important;
    backdrop-filter: blur(16px) !important;
    padding: 40px 36px !important;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

@media (max-width: 576px) {
    .auth-box {
        max-width: 100% !important;
        width: 100% !important;
        padding: 24px 16px !important;
        border-radius: 12px !important;
    }
}

.logo img {
    max-height: 60px;
    margin-bottom: 16px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.05));
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.4s ease-out forwards;
}

/* Header styling */
.login-header {
    margin-bottom: 24px;
}

.login-header h4 {
    font-size: 1.45rem;
    font-weight: 750;
    color: #0f172a;
    letter-spacing: -0.5px;
    margin-bottom: 6px;
}

.login-header p {
    font-size: 0.9rem;
    color: #64748b;
    margin-bottom: 0;
    line-height: 1.4;
}

/* Remove nested cards styles */
.login-card {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100%;
    max-width: 100% !important;
}

/* Form labels & controls */
label.form-label, .form-group label {
    font-weight: 600 !important;
    font-size: 0.875rem !important;
    color: #334155 !important;
    margin-bottom: 8px;
    display: inline-block;
    letter-spacing: 0.1px;
}

.form-select, select.form-control {
    height: 48px !important;
    border-radius: 10px !important;
    border: 1.5px solid #cbd5e1 !important;
    background-color: #fff !important;
    color: #0f172a !important;
    font-weight: 500 !important;
    padding: 0 16px !important;
    font-size: 0.95rem !important;
    transition: all 0.2s ease;
    box-shadow: none !important;
    width: 100%;
}

.form-select:focus, select.form-control:focus {
    border-color: #3b82f6 !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15) !important;
}

/* Modern system cards */
.system-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 15px;
}

.system-card {
    display: flex;
    flex-direction: column;
    padding: 16px 20px;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.system-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: transparent;
    transition: background 0.2s ease;
}

.system-card:hover {
    border-color: #3b82f6;
    background: #f8fafc;
    transform: translateY(-1.5px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.05);
}

.system-card:hover::before {
    background: #3b82f6;
}

.system-card.new-system {
    border-color: #e2e8f0;
}

.system-card.new-system:hover {
    border-color: #10b981;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.05);
}

.system-card.new-system:hover::before {
    background: #10b981;
}

.system-card h6 {
    margin: 0 0 4px 0;
    font-weight: 700;
    font-size: 0.95rem;
    color: #1e293b;
    display: flex;
    align-items: center;
    gap: 6px;
}

.system-card .badge-recommended {
    background: #d1fae5;
    color: #065f46;
    font-size: 0.7rem;
    padding: 2px 8px;
    border-radius: 9999px;
    font-weight: 600;
    letter-spacing: 0.1px;
}

.system-card p {
    font-size: 0.8rem;
    color: #64748b;
    margin: 0;
    line-height: 1.4;
}

/* Input groups with icons */
.input-group {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.01);
    display: flex;
    width: 100%;
}

.input-group .form-control {
    border: 1.5px solid #cbd5e1 !important;
    border-left: none !important;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
    border-top-right-radius: 10px !important;
    border-bottom-right-radius: 10px !important;
    height: 48px !important;
    font-size: 0.95rem;
    font-weight: 500;
    color: #1e293b;
    transition: all 0.2s ease;
    box-shadow: none !important;
    flex: 1;
    padding-left: 12px !important;
}

.input-group-prepend .input-group-text {
    border: 1.5px solid #cbd5e1 !important;
    border-right: none !important;
    background-color: #f8fafc !important;
    color: #64748b;
    font-size: 0.95rem;
    padding: 0 16px;
    border-top-left-radius: 10px !important;
    border-bottom-left-radius: 10px !important;
    display: flex;
    align-items: center;
    justify-content: center;
}

.input-group-append .input-group-text {
    border: 1.5px solid #cbd5e1 !important;
    border-left: none !important;
    background-color: #f8fafc !important;
    color: #64748b;
    font-size: 0.95rem;
    padding: 0 16px;
    border-top-right-radius: 10px !important;
    border-bottom-right-radius: 10px !important;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Highlight group on focus */
.input-group:focus-within .input-group-text {
    border-color: #3b82f6 !important;
    color: #3b82f6;
}

.input-group:focus-within .form-control {
    border-color: #3b82f6 !important;
}

/* Captcha Section styling */
#captchadiv {
    background: #f8fafc;
    border: 1.5px solid #cbd5e1;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 48px;
    width: 100%;
    overflow: hidden;
}

#captchadiv img {
    height: 100% !important;
    width: 100% !important;
    object-fit: contain;
}

#reloadcaptcha {
    height: 48px !important;
    border-radius: 10px !important;
    font-weight: 600;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s ease;
    border: none !important;
    background: #f59e0b !important;
    color: #fff !important;
}

#reloadcaptcha:hover {
    background: #d97706 !important;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(245, 158, 11, 0.15);
}

#reloadcaptcha:active {
    transform: translateY(0);
}

/* Submit & Reset buttons styling */
.btn-primary-gradient {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%) !important;
    border: none !important;
    color: #fff !important;
    font-weight: 600 !important;
    letter-spacing: 0.3px;
    height: 48px;
    border-radius: 10px !important;
    box-shadow: 0 3px 8px rgba(37, 99, 235, 0.15) !important;
    transition: all 0.2s ease !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 0.95rem !important;
}

.btn-primary-gradient:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2) !important;
}

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

.btn-secondary-light {
    background: #f1f5f9 !important;
    border: 1.5px solid #cbd5e1 !important;
    color: #475569 !important;
    font-weight: 600 !important;
    height: 48px;
    border-radius: 10px !important;
    transition: all 0.2s ease !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    font-size: 0.95rem !important;
}

.btn-secondary-light:hover {
    background: #e2e8f0 !important;
    color: #1e293b !important;
}

/* Back button */
.btn-back-link {
    background: none;
    border: none;
    color: #3b82f6;
    font-weight: 600;
    font-size: 0.8rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 0;
    margin-bottom: 15px;
    transition: color 0.2s ease;
}

.btn-back-link:hover {
    color: #1d4ed8;
    text-decoration: none;
}

/* Alert messages styling */
.alert-dismissible .close {
    padding: 0.6rem 0.8rem !important;
}
