/* NP Tool Web GUI - 样式表 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 10px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    overflow: hidden;
}

.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 5px;
    text-align: center;
}

.header h1 {
    font-size: 2em;
    margin-bottom: 10px;
}

.header p {
    opacity: 0.9;
}

.content {
    padding: 30px;
}

.section {
    margin-bottom: 30px;
}

.section-title {
    font-size: 1.3em;
    color: #333;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #667eea;
}

/* 文件上传区域 */
.upload-area {
    border: 3px dashed #667eea;
    border-radius: 10px;
    padding: 40px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    background: #f8f9ff;
}

.upload-area:hover {
    background: #eef0ff;
    border-color: #764ba2;
}

.upload-area.dragover {
    background: #e0e4ff;
    border-color: #764ba2;
}

.upload-icon {
    font-size: 3em;
    margin-bottom: 10px;
}

.file-input {
    display: none;
}

.apk-info {
    margin-top: 20px;
    padding: 15px;
    background: #f0f4ff;
    border-radius: 5px;
    display: none;
}

.apk-info.show {
    display: block;
}

.info-item {
    margin: 5px 0;
    color: #555;
}

.info-label {
    font-weight: bold;
    color: #333;
}

/* 参数配置 */
.params-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 10px;
}

.param-item {
    display: flex;
    align-items: center;
    padding: 6px 8px;
    background: #f8f9fa;
    border-radius: 4px;
    transition: all 0.2s;
}

.param-item:hover {
    background: #e9ecef;
}

.param-item input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin-right: 8px;
    cursor: pointer;
}

.param-item label {
    cursor: pointer;
    flex: 1;
    color: #333;
    font-size: 0.9em;
}

.param-desc {
    font-size: 0.75em;
    color: #888;
    margin-left: 24px;
    margin-top: 2px;
}

/* 按钮 */
.btn {
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    font-size: 1em;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: bold;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-group {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

/* 进度条 */
.progress-container {
    margin: 20px 0;
    display: none;
}

.progress-container.show {
    display: block;
}

.progress-bar {
    width: 100%;
    height: 30px;
    background: #e9ecef;
    border-radius: 15px;
    overflow: hidden;
    position: relative;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    width: 0%;
    transition: width 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
}

/* 日志区域 */
.log-container {
    margin-top: 20px;
    background: #1e1e1e;
    border-radius: 5px;
    padding: 15px;
    max-height: 400px;
    overflow-y: auto;
    font-family: 'Consolas', 'Courier New', monospace;
    font-size: 0.9em;
    display: none;
}

.log-container.show {
    display: block;
}

.log-line {
    color: #d4d4d4;
    margin: 2px 0;
    line-height: 1.5;
}

.log-line.info {
    color: #4ec9b0;
}

.log-line.success {
    color: #6a9955;
}

.log-line.error {
    color: #f44747;
}

.log-line.warning {
    color: #dcdcaa;
}

/* 结果展示 */
.result-container {
    margin-top: 20px;
    padding: 20px;
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 5px;
    display: none;
}

.result-container.show {
    display: block;
}

.result-title {
    font-size: 1.2em;
    color: #155724;
    margin-bottom: 10px;
}

.result-item {
    margin: 8px 0;
    color: #155724;
}

/* 加载动画 */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
    margin-right: 10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}
