* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* 导航条样式 */
.navbar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

.nav-logo h2 {
    color: white;
    font-size: 1.5rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-link {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #f0f0f0;
}

/* 内容区域样式 */
.content-area {
    flex: 1;
    padding: 2rem 0;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.content-scroll {
    height: 400px;
    overflow-y: scroll;
    padding: 1rem;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: #fafafa;
}

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

.content-scroll::-webkit-scrollbar-thumb {
    background-color: #667eea;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

.content-scroll::-webkit-scrollbar-thumb:hover {
    background-color: #5a6fd8;
}

/* 页脚样式 */
.footer {
    background: #333;
    color: white;
    padding: 2rem 0;
    margin-top: auto;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    padding: 0 2rem;
}

.footer-section h3 {
    margin-bottom: 1rem;
    color: #667eea;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section a {
    color: #ccc;
    text-decoration: none;
}

.footer-section a:hover {
    color: white;
}

/* 自定义弹窗样式 */
.custom-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 999;
    animation: slideInRight 0.3s ease-out;
    max-width: 400px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
}

.toast-content {
    border-radius: 8px;
    padding: 16px;
    min-width: 320px;
}

.toast-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.toast-title-area {
    display: flex;
    align-items: center;
    gap: 8px;
}

.toast-icon {
    width: 20px;
    height: 20px;
    color: #374151;
}

.toast-title {
    font-weight: 600;
    font-size: 14px;
    color: #374151;
}

.toast-close {
    background: none;
    border: none;
    font-size: 18px;
    color: #6b7280;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s;
}

.toast-close:hover {
    background-color: rgba(0, 0, 0, 0.1);
    color: #374151;
}

.toast-message {
    font-size: 13px;
    color: #4b5563;
    line-height: 1.5;
    margin-left: 28px;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* 模态对话框样式 */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* 兼容HTML中的.modal类 */
.modal {
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(-20px);
    transition: transform 0.3s ease;
    z-index: 1001; /* 确保模态框内容位于遮罩层上方 */
}

.modal-overlay.active .modal {
    transform: translateY(0);
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-dialog {
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    transform: translateY(-20px);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal-dialog {
    transform: translateY(0);
}

.modal-header {
    padding: 24px;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #f8fafc;
}

.modal-title {
    font-size: 22px;
    font-weight: 600;
    color: #333;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #999;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background-color: #f5f5f5;
    color: #333;
}

.modal-body {
    padding: 24px;
    font-size: 16px;
    line-height: 1.6;
    color: #555;
}

.modal-footer {
    padding: 20px 24px;
    border-top: 1px solid #e0e0e0;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.modal-btn {
    padding: 10px 24px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.modal-btn-primary {
    background-color: #667eea;
    color: white;
}

.modal-btn-primary:hover {
    background-color: #5a6fd8;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.modal-btn-secondary {
    background-color: #f5f5f5;
    color: #666;
}

.modal-btn-secondary:hover {
    background-color: #e0e0e0;
    transform: translateY(-1px);
}

/* 简单模态对话框变体（只有一个按钮） */
.modal-dialog.simple .modal-footer {
    justify-content: center;
}

/* 加载状态样式 */
.modal-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin-right: 12px;
}

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

/* 响应式设计 */
@media (max-width: 768px) {
    .modal-dialog {
        margin: 20px;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 16px;
    }
    
    .modal-title {
        font-size: 16px;
    }
    
    .modal-body {
        font-size: 14px;
    }
}

/* 统一遮罩层样式 */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
    z-index: 999;
    display: block;
    overflow: hidden;
}

/* 统一隐藏类样式 */
.hidden {
    display: none !important;
}

/* 毛玻璃淡绿色按钮样式 */
.btn-frosted-green {
    background: rgba(16, 185, 129, 0.25) !important;
    color: #065f46 !important;
    border-radius: 6px !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: 2px solid rgba(16, 185, 129, 0.3) !important;
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.15) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    padding: 10px 20px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
}

.btn-frosted-green:hover {
    background: rgba(16, 185, 129, 0.35) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 30px rgba(16, 185, 129, 0.25) !important;
    border: 2px solid rgba(16, 185, 129, 0.45) !important;
}

.btn-frosted-blue {
    background: rgba(59, 130, 246, 0.25) !important;
    color: #1e40af !important;
    border-radius: 6px !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: 2px solid rgba(59, 130, 246, 0.3) !important;
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.15) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    padding: 10px 20px !important;
    font-size: 14px !important;
}

.btn-frosted-blue:hover {
    background: rgba(59, 130, 246, 0.35) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 30px rgba(59, 130, 246, 0.25) !important;
    border: 2px solid rgba(59, 130, 246, 0.45) !important;
}

.btn-frosted-red {
    background: rgba(239, 68, 68, 0.25) !important;
    color: #991b1b !important;
    border-radius: 6px !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: 2px solid rgba(239, 68, 68, 0.3) !important;
    box-shadow: 0 4px 20px rgba(239, 68, 68, 0.15) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    padding: 10px 20px !important;
    font-size: 14px !important;
}

.btn-frosted-red:hover {
    background: rgba(239, 68, 68, 0.35) !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 30px rgba(239, 68, 68, 0.25) !important;
    border: 2px solid rgba(239, 68, 68, 0.45) !important;
}