/* 日志区域优化 */
.log-section {
    margin-top: 20px;
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
}

.log-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #4a5568;
    background: #edf2f7;
    border-bottom: 1px solid #e2e8f0;
}

.log-panel {
    background: #ffffff;
    color: #4a5568;
    padding: 16px;
    font-family: 'Menlo', 'Monaco', 'Courier New', monospace;
    font-size: 0.85rem;
    height: 450px;
    overflow-y: auto;
    white-space: pre-wrap;
    word-break: break-all;
    line-height: 1.5;
    resize: vertical;
    min-height: 200px;
}

/* POSTMAN风格日志样式 */
.log-request-block {
    margin: 12px 0;
    padding: 12px;
    background: #f7fafc;
    border-left: 4px solid #4299e1;
    border-radius: 4px;
}

.log-request-line {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
    font-weight: 600;
}

.log-method {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.log-method-get {
    background: #48bb78;
    color: white;
}

.log-method-post {
    background: #ed8936;
    color: white;
}

.log-method-put {
    background: #4299e1;
    color: white;
}

.log-method-delete {
    background: #f56565;
    color: white;
}

.log-url {
    color: #2d3748;
    font-size: 0.85rem;
    word-break: break-all;
}

.log-request-data {
    margin-top: 8px;
    padding: 8px;
    background: white;
    border-radius: 4px;
    border: 1px solid #e2e8f0;
}

.log-header-item {
    color: #718096;
    font-size: 0.8rem;
    margin-bottom: 8px;
}

.log-body-title {
    color: #4a5568;
    font-weight: 600;
    font-size: 0.8rem;
    margin: 8px 0 4px 0;
}

.log-body-content {
    padding: 8px;
    background: #f8fafc;
    border-radius: 4px;
}

.log-param-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 0;
    font-size: 0.8rem;
}

.log-param-key {
    color: #2d3748;
    font-weight: 600;
    min-width: 120px;
}

.log-param-type {
    color: #805ad5;
    font-size: 0.75rem;
    padding: 2px 6px;
    background: #faf5ff;
    border-radius: 3px;
}

.log-param-value {
    color: #4a5568;
    word-break: break-all;
}

.log-response-block {
    margin: 12px 0;
    padding: 12px;
    background: #f7fafc;
    border-left: 4px solid #48bb78;
    border-radius: 4px;
}

.log-response-line {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
    font-weight: 600;
}

.log-response-label {
    color: #4a5568;
    font-size: 0.85rem;
}

.log-status {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
}

.log-status-success {
    background: #c6f6d5;
    color: #22543d;
}

.log-status-error {
    background: #fed7d7;
    color: #742a2a;
}

.log-status-info {
    background: #bee3f8;
    color: #2c5282;
}

.log-response-data {
    margin-top: 8px;
    padding: 12px;
    background: white;
    border-radius: 4px;
    border: 1px solid #e2e8f0;
    font-size: 0.8rem;
    color: #2d3748;
    max-height: 400px;
    overflow-y: auto;
}

/* 普通日志样式 */
.log-line {
    margin: 8px 0;
    padding: 6px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
}

.log-data {
    margin: 4px 0 8px 0;
    padding: 12px;
    background: #f8fafc;
    border-radius: 4px;
    border: 1px solid #e2e8f0;
    font-size: 0.8rem;
    color: #2d3748;
    max-height: 300px;
    overflow-y: auto;
}

.log-info {
    background: #ebf8ff;
    color: #2c5282;
}

.log-warn {
    background: #fefcbf;
    color: #744210;
}

.log-error {
    background: #fed7d7;
    color: #742a2a;
}

.btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    padding: 4px;
    border-radius: 4px;
    transition: background 0.2s;
}
.btn-icon:hover { background: #e2e8f0; }
