.aic-tools-dashboard {
    background: #f8f9fa;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    min-height: 600px;
    border: 1px solid #eee;
}

/* 导航栏 */
.aic-tools-nav {
    display: flex;
    background: #fff;
    border-bottom: 1px solid #eee;
    padding: 0 10px;
}
.aic-nav-btn {
    padding: 18px 20px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-weight: 600;
    color: #666;
    border-bottom: 3px solid transparent;
    transition: all 0.2s;
    font-size: 15px;
}
.aic-nav-btn:hover { color: #0d6efd; background: #f8f9fa; }
.aic-nav-btn.active { color: #0d6efd; border-bottom-color: #0d6efd; }

/* 面板容器 */
.aic-tool-panel { display: none; padding: 30px; animation: fadeIn 0.3s ease; }
.aic-tool-panel.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }

/* 分组标题 */
.aic-section-title {
    margin-bottom: 15px;
    border-left: 4px solid #0d6efd;
    padding-left: 10px;
    font-size: 16px;
    color: #333;
    font-weight: bold;
}

/* 网格布局 */
.aic-tool-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
}

/* 工具卡片 */
.aic-tool-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    padding: 25px;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}
.aic-tool-card:hover { transform: translateY(-3px); box-shadow: 0 10px 25px rgba(0,0,0,0.08); border-color: #0d6efd; }
.aic-tool-card.wide-card { grid-column: span 2; } /* 宽卡片 */

.card-icon { font-size: 40px; margin-bottom: 15px; }
.aic-tool-card h3 { margin: 0 0 8px 0; font-size: 18px; color: #333; }
.aic-tool-card p { color: #777; font-size: 13px; margin-bottom: 20px; flex-grow: 1; line-height: 1.5; }

/* 控件组 */
.aic-control-group { margin-bottom: 15px; }
.aic-control-group select, .aic-control-group input {
    padding: 6px; border: 1px solid #ddd; border-radius: 4px; width: 100%; box-sizing: border-box;
}

/* 上传区域 */
.aic-upload-zone {
    border: 2px dashed #ddd;
    border-radius: 8px;
    padding: 15px;
    background: #fcfcfc;
    text-align: center;
    transition: border-color 0.2s;
}
.aic-upload-zone:hover { border-color: #0d6efd; background: #f0f7ff; }
.file-list { margin: 10px 0; font-size: 12px; color: #555; text-align: left; max-height: 60px; overflow-y: auto; }

/* 按钮 */
.aic-btn-upload {
    background: #fff; border: 1px solid #0d6efd; color: #0d6efd;
    padding: 6px 12px; border-radius: 4px; cursor: pointer; font-size: 13px;
}
.aic-btn-upload:hover { background: #0d6efd; color: #fff; }

.aic-btn-start {
    background: #0d6efd; color: #fff; border: none;
    padding: 8px 20px; border-radius: 6px; cursor: pointer; font-size: 14px; font-weight: 500;
    margin-top: 10px; width: 100%; transition: background 0.2s;
}
.aic-btn-start:hover { background: #0b5ed7; }
.aic-btn-start:disabled { background: #ccc; cursor: not-allowed; }

.aic-btn-download {
    display: inline-block; background: #198754; color: #fff;
    padding: 8px 15px; border-radius: 6px; text-decoration: none; font-size: 13px; margin-top: 10px;
}
.aic-btn-download:hover { background: #157347; color: #fff; }

.aic-btn-sm {
    padding: 5px 10px;
    font-size: 12px;
    border-radius: 4px;
    border: 1px solid #ddd;
    background: #fff;
    cursor: pointer;
}
.aic-btn-sm:hover { background: #f0f0f0; }

/* 复杂布局 (Flex) */
.aic-flex-row { display: flex; gap: 20px; align-items: flex-start; }
.flex-grow { flex: 1; }
.aic-action-zone { width: 200px; flex-shrink: 0; }

/* 输入框 */
.aic-input-text {
    width: 100%; padding: 8px; border: 1px solid #ddd; border-radius: 4px; box-sizing: border-box; margin-bottom: 10px;
}

/* 结果框 */
.aic-result-box {
    margin-top: 15px; padding: 10px; background: #f1f3f5; border-radius: 6px; font-size: 13px; color: #333;
    max-height: 150px; overflow-y: auto; white-space: pre-wrap; border: 1px solid #e9ecef;
}
.aic-result-image img { max-width: 100%; border-radius: 6px; border: 1px solid #ddd; }

/* 业务板块 (Business Section) */
.aic-business-section {
    background: #fff; border: 1px solid #e0e0e0; border-radius: 10px; margin-bottom: 20px; overflow: hidden;
}
.section-header {
    padding: 20px; display: flex; align-items: center; gap: 15px; background: #fff;
}
.section-header .icon { font-size: 32px; }
.section-header .text { flex: 1; }
.section-header h4 { margin: 0 0 5px 0; font-size: 16px; }
.section-header p { margin: 0; color: #777; font-size: 13px; }

.aic-wizard-container, .aic-form-layout {
    padding: 20px; border-top: 1px solid #eee; background: #fcfcfc;
}

/* 标书双上传 */
.aic-dual-upload { display: flex; gap: 20px; margin-bottom: 20px; }
.aic-dual-upload .upload-box { flex: 1; border: 2px dashed #ddd; padding: 15px; border-radius: 8px; background: #fff; }
.aic-dual-upload label { display: block; font-weight: bold; margin-bottom: 10px; font-size: 13px; }
.desc-sm { color: #888; font-size: 12px; margin-top: 5px; }

/* 加载动画 */
.spinner {
    width: 30px; height: 30px; border: 3px solid #f3f3f3; border-top: 3px solid #0d6efd;
    border-radius: 50%; animation: spin 1s linear infinite; margin: 0 auto 10px;
}
@keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }

/* 模态弹窗样式 (新增) */
.aic-modal {
    display: none; 
    position: fixed; 
    z-index: 9999; 
    left: 0; top: 0; 
    width: 100%; height: 100%; 
    overflow: auto; 
    background-color: rgba(0,0,0,0.5); 
    animation: fadeIn 0.3s;
}

.aic-modal-content {
    background-color: #fefefe;
    margin: 15% auto; 
    padding: 25px;
    border: 1px solid #888;
    width: 400px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    position: relative;
}

.aic-close-modal {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    right: 15px;
    top: 5px;
}

.aic-close-modal:hover,
.aic-close-modal:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

/* 响应式 */
@media (max-width: 768px) {
    .aic-tool-grid { grid-template-columns: 1fr; }
    .aic-tool-card.wide-card { grid-column: span 1; }
    .aic-flex-row { flex-direction: column; }
    .aic-action-zone { width: 100%; }
    .aic-dual-upload { flex-direction: column; }
    .aic-modal-content { width: 90%; margin: 30% auto; }
}