/* 全局样式与根变量 */
:root {
    --primary-color: #3b82f6;
    --secondary-color: #1d4ed8;
    --accent-color: #8b5cf6;
    --text-primary: #ffffff;
    --text-secondary: #1f2937;
    --text-muted: rgba(255, 255, 255, 0.7);
    --border-color: rgba(255, 255, 255, 0.1);
    --glass-bg: rgba(255, 255, 255, 0.05);
    --input-bg: rgba(0, 0, 0, 0.5);
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* 通用动画类 */
.fade-in {
    animation: fadeIn 0.3s ease-out;
}

.pulse {
    animation: pulse 2s infinite;
}

.spin {
    animation: spin 1s linear infinite;
}

/* 连接状态指示器 */
.status-online {
    background-color: #10b981;
    /* green-500 */
}

.status-offline {
    background-color: #ef4444;
    /* red-500 */
}

.status-connecting {
    background-color: #f59e0b;
    /* yellow-500 */
}

/* 表单错误状态 */
.form-input.error {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-input.error:focus {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2);
}

/* 链接样式 */
.link {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.2s ease;
}

.link:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

/* 主机卡片样式 */
.host-card {
    transition: all 0.2s ease-in-out;
    border: 1px solid #e5e7eb;
}

.host-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.host-card.online {
    border-left: 4px solid #10b981;
}

.host-card.offline {
    border-left: 4px solid #6b7280;
}

/* 按钮样式增强 */
.btn-primary {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    transition: all 0.2s ease-in-out;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #1d4ed8, #1e40af);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    transition: all 0.2s ease-in-out;
}

.btn-success:hover {
    background: linear-gradient(135deg, #059669, #047857);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    transition: all 0.2s ease-in-out;
}

.btn-danger:hover {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

/* 加载状态 */
.loading {
    position: relative;
    pointer-events: none;
}

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

/* 消息提示样式 */
.toast {
    transition: all 0.3s ease-in-out;
    transform: translateX(100%);
}

.toast.show {
    transform: translateX(0);
}

.toast.success {
    background-color: #10b981;
}

.toast.error {
    background-color: #ef4444;
}

.toast.warning {
    background-color: #f59e0b;
}

.toast.info {
    background-color: #3b82f6;
}

/* 模态框动画 */
.modal {
    transition: all 0.3s ease-in-out;
    opacity: 0;
}

.modal.show {
    opacity: 1;
}

.modal-content {
    transition: all 0.3s ease-in-out;
    transform: scale(0.9);
}

.modal.show .modal-content {
    transform: scale(1);
}

/* 响应式设计 */
@media (max-width: 640px) {
    .host-card {
        margin-bottom: 1rem;
    }

    .host-card .flex {
        flex-direction: column;
        align-items: flex-start;
    }

    .host-card .space-x-2 {
        margin-top: 0.5rem;
        width: 100%;
    }

    .host-card .space-x-2>* {
        margin-right: 0;
        margin-bottom: 0.5rem;
        width: 100%;
    }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* 表单输入框焦点样式 */
/* input:focus {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
} */

/* 禁用状态 */
.disabled {
    opacity: 0.6;
    pointer-events: none;
}

/* 工具提示 */
.tooltip {
    position: relative;
}

.tooltip::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: #1f2937;
    color: white;
    padding: 0.5rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s;
    z-index: 1000;
}

.tooltip:hover::before {
    opacity: 1;
}

/* 状态徽章 */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.5rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
}

.badge.online {
    background-color: #dcfce7;
    color: #166534;
}

.badge.offline {
    background-color: #f3f4f6;
    color: #374151;
}

.badge.connecting {
    background-color: #fef3c7;
    color: #92400e;
}

/* 登录界面黑色半透明风格 */
.login-container {
    height: 100vh;
    height: 100svh;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #0f0f23 0%, #1a1a2e 50%, #16213e 100%);
}

.login-card {
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 3rem;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    position: relative;
    z-index: 10;
    animation: slideInUp 0.6s ease-out;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
}

.login-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.logo-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 16px rgba(59, 130, 246, 0.3);
}

.logo-icon svg {
    width: 24px;
    height: 24px;
    color: white;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.login-title {
    font-size: 2rem;
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 0.5rem 0;
    letter-spacing: -0.02em;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.login-subtitle {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    margin: 0;
    line-height: 1.5;
}

.login-form {
    margin-bottom: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
    position: relative;
}

.form-group.focused .form-label {
    color: var(--primary-color);
    transform: translateY(-2px);
}

.form-group.focused .form-input {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    background-color: rgba(255, 255, 255, 0.15) !important;
    background: rgba(255, 255, 255, 0.15) !important;
    -webkit-box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1), 0 0 0 1000px rgba(255, 255, 255, 0.15) inset !important;
}

.form-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.label-icon {
    width: 16px;
    height: 16px;
    opacity: 0.7;
    color: rgba(255, 255, 255, 0.7);
}

.form-input {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    font-size: 1rem;
    background: rgba(255, 255, 255, 0.1) !important;
    color: #ffffff;
    transition: all 0.2s ease;
    outline: none;
    -webkit-box-shadow: 0 0 0 1000px rgba(255, 255, 255, 0.1) inset !important;
    box-shadow: 0 0 0 1000px rgba(255, 255, 255, 0.1) inset !important;
}

.form-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2), 0 0 0 1000px rgba(255, 255, 255, 0.15) inset !important;
    -webkit-box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2), 0 0 0 1000px rgba(255, 255, 255, 0.15) inset !important;
    background: rgba(255, 255, 255, 0.15) !important;
}

.form-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 1.5rem 0;
}

.checkbox-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    user-select: none;
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

.checkbox-container input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary-color);
    border-radius: 4px;
}

.checkbox-text {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
}

.forgot-password {
    color: #60a5fa;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.forgot-password:hover {
    color: #93c5fd;
    text-decoration: underline;
}

.btn-login {
    width: 100%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 1rem;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(59, 130, 246, 0.4);
}

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

.btn-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.btn-icon {
    width: 18px;
    height: 18px;
}

.btn-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.loading-spinner {
    width: 18px;
    height: 18px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.login-divider {
    display: flex;
    align-items: center;
    margin: 2rem 0 1.5rem 0;
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
}

.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-color), transparent);
}

.login-divider span {
    padding: 0 1rem;
    background: rgba(0, 0, 0, 0.7);
}

.btn-sso {
    width: 100%;
    background: rgba(255, 255, 255, 0.8);
    color: var(--text-secondary);
    border: 2px solid var(--border-color);
    padding: 0.875rem 1rem;
    border-radius: 12px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    backdrop-filter: blur(10px);
}

.btn-sso:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
}

.login-footer {
    margin-top: 2.5rem;
    text-align: center;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.footer-link {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s ease;
}

.footer-link svg {
    width: 14px;
    height: 14px;
}

.footer-link:hover {
    color: #60a5fa;
}

.footer-info {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.8rem;
    line-height: 1.4;
}

.version-info {
    opacity: 0.7;
    margin-top: 0.25rem;
}

/* 背景装饰 */
.login-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    overflow: hidden;
}

.bg-gradient {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.6;
    animation: float 6s ease-in-out infinite;
}

.bg-gradient-1 {
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, #1e3a8a 0%, #312e81 100%);
    top: -150px;
    left: -150px;
    animation-delay: 0s;
}

.bg-gradient-2 {
    width: 400px;
    height: 400px;
    background: linear-gradient(135deg, #7c3aed 0%, #3730a3 100%);
    bottom: -200px;
    right: -200px;
    animation-delay: 3s;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px) rotate(0deg);
    }

    50% {
        transform: translateY(-20px) rotate(5deg);
    }
}

.bg-particles {
    position: absolute;
    width: 100%;
    height: 100%;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(59, 130, 246, 0.8);
    border-radius: 50%;
    animation: particle-float 8s linear infinite;
    /* 增加可见性和调试友好 */
    box-shadow: 0 0 8px rgba(59, 130, 246, 0.4);
    opacity: 1;
}

.particle:nth-child(1) {
    left: 20%;
    animation-delay: 0s;
    animation-duration: 8s;
}

.particle:nth-child(2) {
    left: 40%;
    animation-delay: 2s;
    animation-duration: 10s;
}

.particle:nth-child(3) {
    left: 60%;
    animation-delay: 4s;
    animation-duration: 12s;
}

.particle:nth-child(4) {
    left: 80%;
    animation-delay: 6s;
    animation-duration: 9s;
}

.particle:nth-child(5) {
    left: 90%;
    animation-delay: 8s;
    animation-duration: 11s;
}

@keyframes particle-float {
    0% {
        transform: translateY(100vh) scale(0);
        opacity: 0;
    }

    5% {
        opacity: 0.8;
        transform: translateY(95vh) scale(0.5);
    }

    10% {
        opacity: 1;
        transform: translateY(90vh) scale(1);
    }

    90% {
        opacity: 1;
        transform: translateY(10vh) scale(1);
    }

    95% {
        opacity: 0.8;
        transform: translateY(5vh) scale(0.5);
    }

    100% {
        transform: translateY(-5vh) scale(0);
        opacity: 0;
    }
}

/* OAuth授权界面样式 */
#oauth-auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    background: linear-gradient(135deg, #0f0f23 0%, #1a1a2e 50%, #16213e 100%);
}

#oauth-auth-container .auth-form {
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 3rem;
    width: 100%;
    max-width: 480px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    position: relative;
    animation: slideInUp 0.6s ease-out;
    color: var(--text-primary);
}

#oauth-auth-container .auth-form::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
}

#oauth-auth-container h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 1.8rem;
    font-weight: 600;
    background: linear-gradient(135deg, #ffffff, #e5e7eb);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.oauth-info {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.oauth-info p {
    margin: 0.5rem 0;
    font-size: 0.9rem;
    line-height: 1.5;
}

.oauth-info strong {
    color: var(--primary-color);
    font-weight: 600;
}

.oauth-description {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
    font-style: italic;
}

.auth-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.auth-buttons .btn {
    flex: 1;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    color: white;
}

.btn-secondary {
    background: linear-gradient(135deg, #6b7280, #4b5563);
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #4b5563, #374151);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(107, 114, 128, 0.4);
}

#oauth-message {
    min-height: 1.5rem;
}

#oauth-message .message {
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    margin: 0;
}

#oauth-message .message.info {
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #93c5fd;
}

#oauth-message .message.error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
}

/* Dashboard 样式 */
.main-app {
    background: linear-gradient(135deg, #0f0f23 0%, #1a1a2e 50%, #16213e 100%);
    min-height: 100vh;
    color: #ffffff;
}

/* 导航栏样式 */
.navbar {
    background: rgba(0, 0, 0, 0.4) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.navbar-brand {
    font-weight: 600;
    color: #ffffff !important;
}

/* 状态栏样式 */
.status-bar {
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
}

.status-info {
    color: rgba(255, 255, 255, 0.9);
}

.status-label {
    color: rgba(255, 255, 255, 0.7);
    margin-right: 0.5rem;
    font-size: 0.875rem;
}

.status-value {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 0.9rem;
}

/* 状态栏区域布局 */
.status-section {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.status-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.status-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* 连接状态指示器 */
.status-indicator {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.status-indicator.connected {
    background: rgba(16, 185, 129, 0.2);
    border: 2px solid #10b981;
}

.status-indicator.disconnected {
    background: rgba(239, 68, 68, 0.2);
    border: 2px solid #ef4444;
}

.status-indicator.connecting {
    background: rgba(245, 158, 11, 0.2);
    border: 2px solid #f59e0b;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
}

.status-indicator.connected .status-dot {
    color: #10b981;
    animation: pulse 2s infinite;
}

.status-indicator.disconnected .status-dot {
    color: #ef4444;
}

.status-indicator.connecting .status-dot {
    color: #f59e0b;
    animation: spin 1s linear infinite;
}

/* 统计图标 */
.stats-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
}

.stats-icon svg {
    width: 18px;
    height: 18px;
}

/* 统计详情 */
.stats-details {
    display: flex;
    gap: 1rem;
    margin-top: 0.25rem;
    font-size: 0.75rem;
}

.stat-item.online {
    color: #10b981;
}

.stat-item.offline {
    color: #6b7280;
}

.stat-item.busy {
    color: #f59e0b;
}

/* 用户头像样式 */
.user-avatar {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    margin-right: 0.75rem;
}

.user-avatar svg {
    width: 18px;
    height: 18px;
    color: rgba(255, 255, 255, 0.8);
}

.user-avatar img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

/* 状态项布局 */
.status-item {
    display: flex;
    align-items: center;
}

.status-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.status-section {
    display: flex;
    align-items: center;
}

/* 主内容区域 */
.main-content {
    padding: 2rem;
    min-height: calc(100vh - 200px);
}

/* 主机列表容器样式 */
.host-list-container {
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

/* 主机列表工具栏 */
.host-list-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    gap: 1rem;
    flex-wrap: wrap;
}

.search-container {
    position: relative;
    flex: 1;
    max-width: 300px;
}

.search-input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 2.5rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: #ffffff;
    font-size: 0.9rem;
}

.search-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.search-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.search-icon {
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.5);
    pointer-events: none;
}

.sort-container {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.sort-select {
    padding: 0.5rem 0.75rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    color: #ffffff;
    font-size: 0.875rem;
    cursor: pointer;
}

.sort-select:focus {
    outline: none;
    border-color: var(--primary-color);
}

.refresh-btn {
    padding: 0.5rem;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 6px;
    color: var(--primary-color);
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.refresh-btn:hover {
    background: rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.5);
}

/* 主机统计信息 */
.host-stats {
    display: flex;
    gap: 2rem;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.host-stats .stat-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
}

.host-stats .stat-label {
    color: rgba(255, 255, 255, 0.7);
}

.host-stats .stat-value {
    font-weight: 600;
}

.host-stats .stat-value.online {
    color: #10b981;
}

.host-stats .stat-value.offline {
    color: #6b7280;
}

.host-stats .stat-value.busy {
    color: #f59e0b;
}

/* 空状态样式 */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    color: rgba(255, 255, 255, 0.6);
}

.empty-state h3 {
    color: rgba(255, 255, 255, 0.8);
    margin: 1rem 0 0.5rem 0;
    font-size: 1.25rem;
    font-weight: 600;
}

.empty-state p {
    margin-bottom: 2rem;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* 加载状态 */
.loading-state {
    text-align: center;
    padding: 3rem 2rem;
    color: rgba(255, 255, 255, 0.7);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.spinner {
    width: 32px;
    height: 32px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* 卡片样式 */
.card {
    background: rgba(0, 0, 0, 0.4) !important;
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 16px !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.card-header {
    background: rgba(255, 255, 255, 0.05) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 16px 16px 0 0 !important;
}

.card-title {
    color: #ffffff !important;
    font-weight: 600;
}

.card-body {
    color: rgba(255, 255, 255, 0.9);
}

/* Font Awesome 图标大小控制 */
.fas,
.far,
.fab,
.fa {
    font-size: 1rem !important;
    width: auto !important;
    height: auto !important;
}

.navbar .fas {
    font-size: 1.1rem !important;
    margin-right: 0.5rem;
}

.card-header .fas {
    font-size: 1rem !important;
    margin-right: 0.5rem;
    color: var(--primary-color);
}

.btn .fas {
    font-size: 0.9rem !important;
    margin-right: 0.5rem;
}

/* 强制覆盖Font Awesome的大小类 */
.fa-xs {
    font-size: 0.75rem !important;
}

.fa-sm {
    font-size: 0.875rem !important;
}

.fa-lg {
    font-size: 1.25rem !important;
}

.fa-xl {
    font-size: 1.5rem !important;
}

.fa-2x {
    font-size: 1.5rem !important;
    /* 原本是2rem，现在改为1.5rem */
}

.fa-3x {
    font-size: 2rem !important;
    /* 原本是3rem，现在改为2rem */
}

.fa-4x {
    font-size: 2.5rem !important;
}

.fa-5x {
    font-size: 3rem !important;
}

.fa-6x {
    font-size: 3.5rem !important;
}

.fa-7x {
    font-size: 4rem !important;
}

.fa-8x {
    font-size: 4.5rem !important;
}

.fa-9x {
    font-size: 5rem !important;
}

.fa-10x {
    font-size: 5.5rem !important;
}

/* 特定区域的图标大小控制 */
.text-center .fas.fa-2x {
    font-size: 1.2rem !important;
    /* 搜索图标更小 */
}

.host-list .fas {
    font-size: 1rem !important;
}

.connection-history .fas {
    font-size: 1rem !important;
}

/* 主机列表区域SVG图标大小控制 */
.host-list-container svg {
    width: 16px !important;
    height: 16px !important;
}

.search-icon {
    width: 16px !important;
    height: 16px !important;
}

.refresh-icon {
    width: 16px !important;
    height: 16px !important;
}

.empty-icon {
    width: 48px !important;
    height: 48px !important;
    margin-bottom: 1rem;
}

/* 卡片标题中的图标 */
.card-header .fas {
    font-size: 1rem !important;
    margin-right: 0.5rem;
    color: var(--primary-color);
}

/* 按钮样式 */
.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color)) !important;
    border: none !important;
    border-radius: 8px !important;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    color: #ffffff !important;
    border-radius: 8px !important;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2) !important;
    border-color: rgba(255, 255, 255, 0.3) !important;
}

/* 表单控件样式 */
.form-control {
    background: rgba(0, 0, 0, 0.3) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    color: #ffffff !important;
    border-radius: 8px !important;
}

.form-control:focus {
    background: rgba(0, 0, 0, 0.4) !important;
    border-color: var(--primary-color) !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2) !important;
    color: #ffffff !important;
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.5) !important;
}

.form-label {
    color: rgba(255, 255, 255, 0.9) !important;
    font-weight: 500;
}

/* 模态框样式 */
.modal-content {
    background: rgba(0, 0, 0, 0.9) !important;
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 16px !important;
    color: #ffffff;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
}

.modal-header {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-footer {
    border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.modal-title {
    color: #ffffff !important;
}

.modal-close {
    background: transparent;
    border: none;
    color: #ffffff;
    cursor: pointer;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* 徽章样式 */
.badge {
    border-radius: 6px !important;
}

.bg-secondary {
    background-color: rgba(108, 117, 125, 0.8) !important;
}

/* 进度条样式 */
.progress {
    background-color: rgba(255, 255, 255, 0.1) !important;
    border-radius: 8px !important;
}

.progress-bar {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color)) !important;
}

/* 文本颜色 */
.text-muted {
    color: rgba(255, 255, 255, 0.6) !important;
}

.text-center {
    color: rgba(255, 255, 255, 0.8);
}

/* 加载屏幕 */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #0f0f23 0%, #1a1a2e 50%, #16213e 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.loading-content {
    text-align: center;
    color: #ffffff;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

/* 响应式设计 */
@media (max-width: 480px) {
    .login-container {
        padding: 1rem;
    }

    .login-card {
        padding: 2rem 1.5rem;
        border-radius: 16px;
    }

    .login-title {
        font-size: 1.75rem;
    }

    .footer-links {
        flex-direction: column;
        gap: 1rem;
    }

    #oauth-auth-container {
        padding: 1rem;
    }

    #oauth-auth-container .auth-form {
        padding: 2rem;
        max-width: 100%;
    }

    .auth-buttons {
        flex-direction: column;
    }
}

/* 自动填充样式覆盖 - 修复输入框背景问题 */
input.form-input:-webkit-autofill,
input.form-input:-webkit-autofill:hover,
input.form-input:-webkit-autofill:active,
input.form-input:-webkit-autofill:valid,
input.form-input:-webkit-autofill:invalid,
input.form-input:-webkit-autofill:focus,
input:-webkit-autofill,
#username:-webkit-autofill,
#password:-webkit-autofill,
#registerEmail:-webkit-autofill,
#registerPassword:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 1000px rgba(0, 0, 0, 0.5) inset !important;
    box-shadow: 0 0 0 1000px rgba(0, 0, 0, 0.5) inset !important;
    -webkit-text-fill-color: #ffffff !important;
    caret-color: #ffffff !important;
    background-color: rgba(0, 0, 0, 0.5) !important;
    background: rgba(0, 0, 0, 0.5) !important;
    background-image: none !important;
    transition: background-color 50000s ease-in-out 0s !important;
    -webkit-transition: background-color 50000s ease-in-out 0s !important;
    color: #ffffff !important;
    /* 新增的抗覆盖属性 */
    -webkit-appearance: none !important;
    appearance: none !important;
    background-clip: padding-box !important;
    -webkit-background-clip: padding-box !important;
    filter: none !important;
    -webkit-filter: none !important;
}

input[type="email"]:-webkit-autofill,
input[type="password"]:-webkit-autofill,
input[name="username"]:-webkit-autofill,
input[name="password"]:-webkit-autofill,
input[name="email"]:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 1000px rgba(0, 0, 0, 0.5) inset !important;
    box-shadow: 0 0 0 1000px rgba(0, 0, 0, 0.5) inset !important;
    -webkit-text-fill-color: #ffffff !important;
    background-color: rgba(0, 0, 0, 0.5) !important;
    background: rgba(0, 0, 0, 0.5) !important;
    background-image: none !important;
    transition: background-color 50000s ease-in-out 0s !important;
    -webkit-transition: background-color 50000s ease-in-out 0s !important;
    color: #ffffff !important;
    /* 新增的抗覆盖属性 */
    -webkit-appearance: none !important;
    appearance: none !important;
    background-clip: padding-box !important;
    -webkit-background-clip: padding-box !important;
    filter: none !important;
    -webkit-filter: none !important;
}

input.form-input:-webkit-autofill:focus,
input[type="email"]:-webkit-autofill:focus,
input[type="password"]:-webkit-autofill:focus,
#username:-webkit-autofill:focus,
#password:-webkit-autofill:focus,
#registerEmail:-webkit-autofill:focus,
#registerPassword:-webkit-autofill:focus {
    -webkit-box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2), 0 0 0 1000px rgba(0, 0, 0, 0.5) inset !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2), 0 0 0 1000px rgba(0, 0, 0, 0.5) inset !important;
    -webkit-text-fill-color: #ffffff !important;
    caret-color: #ffffff !important;
    background-color: rgba(0, 0, 0, 0.5) !important;
    background: rgba(0, 0, 0, 0.5) !important;
    background-image: none !important;
    transition: background-color 50000s ease-in-out 0s !important;
    -webkit-transition: background-color 50000s ease-in-out 0s !important;
    color: #ffffff !important;
    /* 新增的抗覆盖属性 */
    -webkit-appearance: none !important;
    appearance: none !important;
    background-clip: padding-box !important;
    -webkit-background-clip: padding-box !important;
    filter: none !important;
    -webkit-filter: none !important;
}

html,
body {
    height: 100%;
    margin: 0;
    overflow: hidden;
    background: linear-gradient(135deg, #0f0f23 0%, #1a1a2e 50%, #16213e 100%);
}